mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-10-23 18:58:44 +08:00
- fixed SCons build on Windows: only build static library (support static/dynamic at the same time requires significant changes)
- renamed SCons glob tool to globtool to avoid clash with python glob module. This prevented running the tests. - check target now works with SCons 1.x
This commit is contained in:
@@ -44,15 +44,15 @@ def valueTreeToString( fout, value, path = '.' ):
|
||||
assert False and "Unexpected value type"
|
||||
|
||||
def parseAndSaveValueTree( input, actual_path ):
|
||||
root = json.read( input )
|
||||
root = json.loads( input )
|
||||
fout = file( actual_path, 'wt' )
|
||||
valueTreeToString( fout, root )
|
||||
fout.close()
|
||||
return root
|
||||
|
||||
def rewriteValueTree( value, rewrite_path ):
|
||||
rewrite = json.write( value )
|
||||
rewrite = rewrite[1:-1] # Somehow the string is quoted ! jsonpy bug ?
|
||||
rewrite = json.dumps( value )
|
||||
#rewrite = rewrite[1:-1] # Somehow the string is quoted ! jsonpy bug ?
|
||||
file( rewrite_path, 'wt').write( rewrite + '\n' )
|
||||
return rewrite
|
||||
|
||||
|
Reference in New Issue
Block a user