Add plugin tests for mjSpec.
Fixes #1903. PiperOrigin-RevId: 663352920 Change-Id: I3a9e17aec5694e49c20b542f4b0a4402f88a2f17
This commit is contained in:
committed by
Copybara-Service
parent
64575f399b
commit
e0e134ca63
@@ -39,8 +39,10 @@ def _value_binding_code(
|
||||
fullvarname = 'ptr->' + varname
|
||||
if field.name.startswith('mjs'): # all other mjs are raw structs
|
||||
fulltype = field.name.replace('mjs', 'raw::Mjs')
|
||||
if field.name != 'mjsPlugin' and field.name != 'mjsOrientation':
|
||||
fulltype = fulltype + '*' # plugin and orientation are pointers
|
||||
if field.name == 'mjsPlugin' or field.name == 'mjsOrientation':
|
||||
fulltype = fulltype + '&' # plugin and orientation are not pointers
|
||||
else:
|
||||
fulltype = fulltype + '*'
|
||||
|
||||
def_property_args = (
|
||||
f'"{varname}"',
|
||||
|
||||
Reference in New Issue
Block a user