Я уже рассказывал про этот аттрибут, который позволяет серилизовать любую структуру. Но недавно я столкнулся с интересным багом, т.к. по мне так это именно баг:
public interface IMyData {}
[System.Serializable] public struct MyStruct { [SerializeReference] public IMyData data; public int references; }
public MyStruct[] items;
Если добавить поле с именем references в эту же структуру где у вас будет SerializeReference, то при компиляции будет ошибка The same field name is serialized multiple times с указанием именно на поле references.
На всякий случай я заглянул в доку и не нашел там ничего про то, что нельзя использовать поле с этим именем.
Я уже рассказывал про этот аттрибут, который позволяет серилизовать любую структуру. Но недавно я столкнулся с интересным багом, т.к. по мне так это именно баг:
public interface IMyData {}
[System.Serializable] public struct MyStruct { [SerializeReference] public IMyData data; public int references; }
public MyStruct[] items;
Если добавить поле с именем references в эту же структуру где у вас будет SerializeReference, то при компиляции будет ошибка The same field name is serialized multiple times с указанием именно на поле references.
На всякий случай я заглянул в доку и не нашел там ничего про то, что нельзя использовать поле с этим именем.
5Telegram Channel avatar size/dimensions The initiatives announced by Perekopsky include monitoring the content in groups. According to the executive, posts identified as lacking context or as containing false information will be flagged as a potential source of disinformation. The content is then forwarded to Telegram's fact-checking channels for analysis and subsequent publication of verified information. The visual aspect of channels is very critical. In fact, design is the first thing that a potential subscriber pays attention to, even though unconsciously. Telegram is a leading cloud-based instant messages platform. It became popular in recent years for its privacy, speed, voice and video quality, and other unmatched features over its main competitor Whatsapp. With the sharp downturn in the crypto market, yelling has become a coping mechanism for many crypto traders. This screaming therapy became popular after the surge of Goblintown Ethereum NFTs at the end of May or early June. Here, holders made incoherent groaning sounds in late-night Twitter spaces. They also role-played as urine-loving Goblin creatures.
from us