Skip to content

Commit f52aef8

Browse files
committed
Updaing the library.py.mako file to import complex type
1 parent 6da61f1 commit f52aef8

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

build/templates/_library.py.mako

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,16 @@ driver_name = config['driver_name']
1212
1313
functions = config['functions']
1414
functions = helper.filter_library_functions(functions)
15+
are_complex_parameters_used = helper.are_complex_parameters_used(functions)
1516
%>\
1617

1718
import ctypes
1819
import ${module_name}.errors as errors
1920
import threading
2021

22+
% if are_complex_parameters_used:
23+
from ${module_name}._complextype import * # noqa: F403
24+
% endif
2125
from ${module_name}._visatype import * # noqa: F403,H303
2226
% for c in config['custom_types']:
2327

generated/nifake/nifake/_library.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import nifake.errors as errors
66
import threading
77

8+
from nifake._complextype import * # noqa: F403
89
from nifake._visatype import * # noqa: F403,H303
910

1011
import nifake.custom_struct as custom_struct # noqa: F401

0 commit comments

Comments
 (0)