mirror of
https://github.com/google/flatbuffers.git
synced 2026-07-02 03:13:57 +00:00
Implements verifier and code gen for swift (#6373)
Updates test cases on linux Adhere to new protocol naming Adds fuzzing Adds documentation Adds support for string unions Updated fuzzer generated code
This commit is contained in:
@@ -14,5 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import Foundation
|
||||
print("Flatbuffers")
|
||||
import FlatBuffers
|
||||
|
||||
@_cdecl("LLVMFuzzerTestOneInput")
|
||||
public func FuzzFlatbuffers(_ start: UnsafeRawPointer, _ count: Int) -> CInt {
|
||||
let bytes = UnsafeRawBufferPointer(start: start, count: count)
|
||||
do {
|
||||
var buffer = ByteBuffer(contiguousBytes: bytes, count: count)
|
||||
let _: Monster = try getCheckedRoot(byteBuffer: &buffer)
|
||||
} catch {
|
||||
}
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user