Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*.re linguist-language=Reason
*.rei linguist-language=Reason
41 changes: 39 additions & 2 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.1.0",
"version": "2.0.0",
"command": "npm",
"options": {
"cwd": "${workspaceRoot}"
Expand Down Expand Up @@ -38,5 +38,42 @@
"loop": true
}
]
}
},
"tasks": [
{
"label": "npm",
"type": "shell",
"command": "npm",
"args": [
"run",
"start"
],
"isBackground": true,
"problemMatcher": {
"fileLocation": "absolute",
"owner": "ocaml",
"background": {
"activeOnStart": false,
"beginsPattern": ">>>> Start compiling",
"endsPattern": ">>>> Finish compiling"
},
"pattern": [
{
"regexp": "^File \"(.*)\", line (\\d+)(?:, characters (\\d+)-(\\d+))?:$",
"file": 1,
"line": 2,
"column": 3,
"endColumn": 4
},
{
"regexp": "^(?:(?:Parse\\s+)?(Warning|[Ee]rror)(?:\\s+\\d+)?:)?\\s+(.*)$",
"severity": 1,
"message": 2,
"loop": true
}
]
},
"group": "build"
}
]
}
15 changes: 5 additions & 10 deletions bsconfig.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,17 @@
// This is the configuration file used by BuckleScript's build system bsb. Its documentation lives here: http://bucklescript.github.io/bucklescript/docson/#build-schema.json
// BuckleScript comes with its own parser for bsconfig.json, which is normal JSON, with the extra support of comments and trailing commas.
{
"name": "bs-typed-array",
"version": "0.1.0",
"sources": {
"dir" : "src",
"subdirs" : true
"dir": "src",
"subdirs": true
},
"package-specs": {
"module": "commonjs",
"in-source": true
},
"suffix": ".bs.js",
"bs-dependencies": [
// add your dependencies here. You'd usually install them normally through `npm install my-dependency`. If my-dependency has a bsconfig.json too, then everything will work seamlessly.
],
"bs-dependencies": [],
"warnings": {
"error" : "+101"
},
"refmt": 3
"error": "+101"
}
}
36 changes: 36 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 3 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,12 @@
"start": "bsb -make-world -w",
"clean": "bsb -clean-world"
},
"keywords": [
"BuckleScript",
"TypedArray"
],
"keywords": [ "Reason", "Rescript", "BuckleScript", "TypedArray" ],
"author": "",
"description": "Bucklescript bindings to TypedArray",
"license": "MIT",
"devDependencies": {
"bs-platform": "^2.2.3"
"bs-platform": "^9.0.2"
},
"repository": {
"type": "git",
Expand All @@ -24,4 +21,4 @@
"bugs": {
"url": "https://github.com/tomp4l/bs-typed-array/issues"
}
}
}
8 changes: 4 additions & 4 deletions src/BsTypedArray_ArrayBuffer.re
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ type t;

[@bs.new] external createWithByteLength : int => t = "ArrayBuffer";

[@bs.get] external byteLength : t => int = "";
[@bs.get] external byteLength : t => int = "byteLength";

[@bs.val] [@bs.scope "ArrayBuffer"] external isView : t => bool = "";
[@bs.val] [@bs.scope "ArrayBuffer"] external isView : t => bool = "isView";

[@bs.send] external slice : (t, int, int) => t = "";
[@bs.send] external slice : (t, int, int) => t = "slice";

[@bs.send] external sliceRest : (t, int) => t = "slice";
[@bs.send] external sliceRest : (t, int) => t = "slice";
Loading