Skip to content

Commit c9e8a8b

Browse files
authored
Merge pull request GaijinEntertainment#1912 from GaijinEntertainment/linq-documentation
bitfield serialization
2 parents b3b41d8 + 722844a commit c9e8a8b

2 files changed

Lines changed: 9 additions & 3 deletions

File tree

include/daScript/ast/ast_expressions.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -709,6 +709,7 @@ namespace das
709709
: ExprConstT(a,i,Type::tBitfield) { __rtti = "ExprConstBitfield"; }
710710
virtual ExpressionPtr clone( const ExpressionPtr & expr ) const override;
711711
auto getValue() const { return ExprConstT::getValue(); };
712+
virtual void serialize( AstSerializer & ser ) override;
712713
TypeDeclPtr bitfieldType;
713714
};
714715

src/builtin/module_builtin_ast_serialize.cpp

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1494,10 +1494,15 @@ namespace das {
14941494
ser << isSmartPtr << ptrType;
14951495
}
14961496

1497-
void ExprConstEnumeration::serialize( AstSerializer & ser ) {
1497+
void ExprConstEnumeration::serialize( AstSerializer & ser ) {
14981498
ExprConst::serialize(ser);
14991499
ser << enumType << text;
1500-
}
1500+
}
1501+
1502+
void ExprConstBitfield::serialize( AstSerializer & ser ) {
1503+
ExprConst::serialize(ser);
1504+
ser << bitfieldType;
1505+
}
15011506

15021507
void ExprConstString::serialize(AstSerializer& ser) {
15031508
ExprConst::serialize(ser);
@@ -2309,7 +2314,7 @@ namespace das {
23092314
}
23102315

23112316
uint32_t AstSerializer::getVersion () {
2312-
static constexpr uint32_t currentVersion = 65;
2317+
static constexpr uint32_t currentVersion = 66;
23132318
return currentVersion;
23142319
}
23152320

0 commit comments

Comments
 (0)