Skip to content

Commit

Permalink
Fix rewrapping Ref<T>
Browse files Browse the repository at this point in the history
  • Loading branch information
SomeRanDev committed Oct 12, 2023
1 parent 05b7d0c commit 3f62eaf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cxxcompiler/Compiler.hx
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,7 @@ class Compiler extends reflaxe.PluginCompiler<Compiler> {
// If the variable is value, and the rvalue can be referenced,
// let's use a reference.
final newType = switch(maybeExpr.expr) {
case TField(_): {
case TField(_) if(!tvarType.isRefOrConstRef()): {
TType(getRefType(), [wrapWithMMType(tvarType, Value)]);
}
case _: null;
Expand Down

0 comments on commit 3f62eaf

Please sign in to comment.