small API changes
This commit is contained in:
parent
3fd8ccb06b
commit
ea51f06783
@ -169,7 +169,7 @@ int Yap_CleanOpaqueVariable(CELL d) {
|
||||
}
|
||||
blob_info = blob_tag - USER_BLOB_START;
|
||||
if (!GLOBAL_OpaqueHandlers)
|
||||
return FALSE;
|
||||
return false;
|
||||
if (!GLOBAL_OpaqueHandlers[blob_info].fail_handler)
|
||||
return true;
|
||||
return (GLOBAL_OpaqueHandlers[blob_info].fail_handler)(d);
|
||||
@ -509,4 +509,4 @@ void Yap_InitBigNums(void) {
|
||||
Yap_InitCPred("string", 1, p_is_string, SafePredFlag);
|
||||
Yap_InitCPred("opaque", 1, p_is_opaque, SafePredFlag);
|
||||
Yap_InitCPred("nb_set_bit", 2, p_nb_set_bit, SafePredFlag);
|
||||
}
|
||||
}
|
@ -390,7 +390,7 @@ typedef YAP_Bool (*YAP_Opaque_CallOnGCRelocate)(YAP_opaque_tag_t, void *,
|
||||
/// opaque variables can interact with the system
|
||||
typedef struct YAP_opaque_handler_struct {
|
||||
YAP_Opaque_CallOnCut cut_handler; //< called at cut, which may be a forward
|
||||
//cut or an exception.
|
||||
// cut or an exception.
|
||||
YAP_Opaque_CallOnFail
|
||||
fail_handler; //< called at exit, it can be used to cleanup resources
|
||||
YAP_Opaque_CallOnWrite write_handler; //< text representation
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -108,12 +108,14 @@ if any(a.startswith(('bdist', 'build', 'install')) for a in sys.argv):
|
||||
(pjoin('share', 'jupyter', 'kernels', KERNEL_NAME), glob(pjoin(dest, '*'))),
|
||||
]
|
||||
mode_loc = pjoin( sysconfig.get_path('platlib'), 'notebook', 'static', 'components', 'codemirror', 'mode', 'prolog')
|
||||
custom_loc = pjoin( sysconfig.get_path('platlib'), 'notebook', 'static', 'custom')
|
||||
try:
|
||||
os.mkdir(mode_loc)
|
||||
os.makedirs(mode_loc)
|
||||
shutil.copy( "${CMAKE_SOURCE_DIR}/misc/editors/prolog.js" , mode_loc)
|
||||
except:
|
||||
pass
|
||||
shutil.copy( "${CMAKE_SOURCE_DIR}/misc/editors/prolog.js" , mode_loc)
|
||||
|
||||
shutil.copy( pjoin( custom_loc, "custom.js") , pjoin( custom_loc, "custom.js.orig"))
|
||||
shutil.copy( "${CMAKE_CURRENT_SOURCE_DIR}/custom.js" , pjoin( custom_loc, "custom.js"))
|
||||
|
||||
extras_require = setuptools_args['extras_require'] = {
|
||||
'test:python_version=="2.7"': ['mock'],
|
||||
@ -124,4 +126,4 @@ if 'setuptools' in sys.modules:
|
||||
setup_args.update(setuptools_args)
|
||||
|
||||
if __name__ == '__main__':
|
||||
setup(**setup_args)
|
||||
setup(**setup_args)
|
Reference in New Issue
Block a user