You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20Lines changed: 20 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -105,6 +105,26 @@ There is also a direct method, `compileStandard`, which is only present on recen
105
105
106
106
Starting from version 0.4.20 a Semver compatible version number can be retrieved on every compiler release, including old ones, using the `semver()` method.
107
107
108
+
#### From version 0.5.0
109
+
110
+
Starting from version 0.5.0 the low-level functions are also exposed:
111
+
-`solc.lowlevel.compileSingle`: the original entry point, supports only a single file
112
+
-`solc.lowlevel.compileMulti`: this supports multiple files, introduced in 0.1.6
113
+
-`solc.lowlevel.compileCallback`: this supports callbacks, introduced in 0.2.1
114
+
-`solc.lowlevel.compileStandard`: this supports the Standard JSON input and output interface, introduced in 0.4.11
115
+
116
+
Example:
117
+
```javascript
118
+
var solc =require('solc')
119
+
var input = {
120
+
'lib.sol':'library L { function f() returns (uint) { return 7; } }',
121
+
'cont.sol':'import "lib.sol"; contract x { function g() { L.f(); } }'
122
+
}
123
+
var output =JSON.parse(solc.lowlevel.compileMulti(JSON.stringify({ sources: input }), 1))
0 commit comments