Skip to content

Commit

Permalink
v3.2.51
Browse files Browse the repository at this point in the history
  • Loading branch information
kujirahand committed Apr 18, 2022
1 parent 835234d commit 2a828b5
Show file tree
Hide file tree
Showing 22 changed files with 207 additions and 107 deletions.
7 changes: 4 additions & 3 deletions batch/pickup_command.nako3
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ REPOSパス=基本パスを「../」で相対パス展開。
['src/plugin_promise.js', 'wnako']
]
拡張プラグイン一覧は[
['nadesiko3-sqlite3/src/nadesiko3-sqlite3.js', 'cnako'],
['nadesiko3-sqlite3sync/nadesiko3-sqlite3sync.js', 'cnako'],
['nadesiko3-sqlite3/nadesiko3-sqlite3.js', 'cnako'],
['nadesiko3-drone/nadesiko3-drone.js', 'cnako'],
['nadesiko3-htmlparser/nadesiko3-htmlparser.js', 'cnako'],
['nadesiko3-websocket/nadesiko3-websocket.js', 'cnako'],
['nadesiko3-ml/nadesiko3-ml.js', 'cnako'],
['nadesiko3-mecab/nadesiko3-mecab.js', 'cnako'],
['nadesiko3-odbc/src/plugin_odbc.js', 'cnako'],
['nadesiko3-mssql/src/plugin_mssql.js', 'cnako'],
['nadesiko3-mysql/src/plugin_mysql.js', 'cnako'],
Expand All @@ -42,7 +42,8 @@ REPOSパス=基本パスを「../」で相対パス展開。
# サポートしない
# 'nadesiko3-firebase/plugin_firebase.js',
# 'nadesiko3-googlehome/plugin_googlehome.js',

# 'nadesiko3-sqlite3sync/nadesiko3-sqlite3sync.js', # 利用は非推奨に

#------------------------
結果データ=「」
基本プラグイン一覧を反復
Expand Down
18 changes: 9 additions & 9 deletions demo/browsers.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ <h2 id="デスクトップ">デスクトップ</h2>

<ul>
<li>IE (11以上)</li>
<li>Edge (99/98/97以上)</li>
<li>Firefox (98/97/96/91以上)</li>
<li>Chrome (100/99/98/97/96以上)</li>
<li>Safari (15.4/15.2-15.3/14.1以上)</li>
<li>Edge (98/97/96以上)</li>
<li>Firefox (96/95/91/78以上)</li>
<li>Chrome (98/97/96/93以上)</li>
<li>Safari (15.2-15.3/15.1/14.1以上)</li>
<li>Opera (83/82以上)</li>
<li>Node.js (17.4.0/16.13.0/14.19.0/12.22.0以上)</li>
<li>Node.js (17.0.0/16.12.0/14.18.0/12.22.0以上)</li>
</ul>

<h2 id="モバイル">モバイル</h2>

<ul>
<li>Safari on iOS (15.4/15.2-15.3/15.0-15.1/14.5-14.8/14.0-14.4/12.2-12.5以上)</li>
<li>Safari on iOS (15.2-15.3/15.0-15.1/14.5-14.8/14.0-14.4/12.2-12.5以上)</li>
<li>Opera Mini (all以上)</li>
<li>Android Browser (99以上)</li>
<li>Android Browser (97以上)</li>
<li>Opera Mobile (64以上)</li>
<li>Chrome for Android (100以上)</li>
<li>Firefox for Android (98以上)</li>
<li>Chrome for Android (97以上)</li>
<li>Firefox for Android (96以上)</li>
<li>UC Browser for Android (12.12以上)</li>
<li>Samsung Internet (16.0/15.0以上)</li>
<li>QQ Browser (10.4以上)</li>
Expand Down
18 changes: 9 additions & 9 deletions doc/browsers.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,21 @@
## デスクトップ

- IE (11以上)
- Edge (99/98/97以上)
- Firefox (98/97/96/91以上)
- Chrome (100/99/98/97/96以上)
- Safari (15.4/15.2-15.3/14.1以上)
- Edge (98/97/96以上)
- Firefox (96/95/91/78以上)
- Chrome (98/97/96/93以上)
- Safari (15.2-15.3/15.1/14.1以上)
- Opera (83/82以上)
- Node.js (17.4.0/16.13.0/14.19.0/12.22.0以上)
- Node.js (17.0.0/16.12.0/14.18.0/12.22.0以上)

## モバイル

- Safari on iOS (15.4/15.2-15.3/15.0-15.1/14.5-14.8/14.0-14.4/12.2-12.5以上)
- Safari on iOS (15.2-15.3/15.0-15.1/14.5-14.8/14.0-14.4/12.2-12.5以上)
- Opera Mini (all以上)
- Android Browser (99以上)
- Android Browser (97以上)
- Opera Mobile (64以上)
- Chrome for Android (100以上)
- Firefox for Android (98以上)
- Chrome for Android (97以上)
- Firefox for Android (96以上)
- UC Browser for Android (12.12以上)
- Samsung Internet (16.0/15.0以上)
- QQ Browser (10.4以上)
Expand Down
Binary file modified node_modules.7z
Binary file not shown.
Binary file modified nodejs.7z
Binary file not shown.
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nadesiko3",
"version": "3.2.47",
"version": "3.2.51",
"description": "Japanese Programming Language",
"main": "src/index.js",
"bin": {
Expand Down Expand Up @@ -139,7 +139,6 @@
"mocha-css": "^1.0.1",
"module-alias": "^2.2.2",
"multer": "^1.4.3",
"nadesiko3-hoge": "0.0.3",
"npm-check-updates": "^12.0.2",
"os-browserify": "^0.3.0",
"path-browserify": "^1.0.1",
Expand All @@ -152,6 +151,7 @@
"ssri": "^8.0.1",
"standard": "^16.0.4",
"stats-webpack-plugin": "^0.7.0",
"stream-browserify": "^3.0.0",
"style-loader": "^3.3.1",
"stylelint": "^14.0.1",
"stylelint-config-standard": "^24.0.0",
Expand Down Expand Up @@ -179,8 +179,7 @@
"webpack": "^5.63.0",
"webpack-bundle-analyzer": "^4.5.0",
"webpack-cli": "^4.9.1",
"ws": "^8.2.3",
"stream-browserify": "^3.0.0"
"ws": "^8.2.3"
},
"dependencies": {
"body-parser": "^1.19.0",
Expand All @@ -195,6 +194,8 @@
"html": "^1.0.0",
"iconv-lite": "^0.6.3",
"marked": "^4.0.0",
"nadesiko3-htmlparser": "^0.0.4",
"nadesiko3-websocket": "^0.0.5",
"node-fetch": "^2.6.6",
"opener": "^1.5.2",
"readline-sync": "^1.4.10",
Expand Down
2 changes: 1 addition & 1 deletion src/browsers.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"and_chr":["100"],"and_ff":["98"],"and_qq":["10.4"],"and_uc":["12.12"],"android":["99"],"baidu":["7.12"],"chrome":["100","99","98","97","96"],"edge":["99","98","97"],"firefox":["98","97","96","91"],"ie":["11"],"ios_saf":["15.4","15.2-15.3","15.0-15.1","14.5-14.8","14.0-14.4","12.2-12.5"],"kaios":["2.5"],"node":["17.4.0","16.13.0","14.19.0","12.22.0"],"op_mini":["all"],"op_mob":["64"],"opera":["83","82"],"safari":["15.4","15.2-15.3","14.1"],"samsung":["16.0","15.0"]}
{"and_chr":["97"],"and_ff":["96"],"and_qq":["10.4"],"and_uc":["12.12"],"android":["97"],"baidu":["7.12"],"chrome":["98","97","96","93"],"edge":["98","97","96"],"firefox":["96","95","91","78"],"ie":["11"],"ios_saf":["15.2-15.3","15.0-15.1","14.5-14.8","14.0-14.4","12.2-12.5"],"kaios":["2.5"],"node":["17.0.0","16.12.0","14.18.0","12.22.0"],"op_mini":["all"],"op_mob":["64"],"opera":["83","82"],"safari":["15.2-15.3","15.1","14.1"],"samsung":["16.0","15.0"]}
17 changes: 9 additions & 8 deletions src/nako3.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ function NakoGen (mode) {
* checkInit?: boolean
* }} Ast
*
* @typedef {(
* | { type: 'func', josi: string[][], pure?: boolean, fn?: Function, return_none: boolean }
* @typedef {
* | { type: 'func', josi: string[][], pure?: boolean, fn?: Function, return_none: boolean, asyncFn: boolean }
* | { type: 'var' | 'const', value: any}
* )} NakoFunction
* } NakoFunction
*/

class NakoCompiler {
Expand Down Expand Up @@ -123,7 +123,7 @@ class NakoCompiler {
this.pluginfiles = {} // 取り込んだファイル一覧
this.isSetter = false // 代入的関数呼び出しを管理(#290)
this.commandlist = new Set() // プラグインで定義された定数・変数・関数の名前
/** @type {Record<string, { josi: string[][], fn: string, type: 'func' }>} */
/** @type {Record<string, { josi: string[][], fn: string, type: 'func', asyncFn: boolean }>} */
this.nako_func = {} // __v1に配置するJavaScriptのコードで定義された関数

this.logger = new NakoLogger()
Expand Down Expand Up @@ -758,7 +758,7 @@ class NakoCompiler {
throw new Error('プラグインの追加でエラー。')
}
// コマンドを登録するか?
if (key === '初期化' || key.substr(0, 1) === '!') { // 登録しない関数名
if (key === '初期化' || key.substring(0, 1) === '!') { // 登録しない関数名
continue
}
this.commandlist.add(key)
Expand Down Expand Up @@ -811,10 +811,11 @@ class NakoCompiler {
* @param {string} key 関数名
* @param {string[][]} josi 助詞
* @param {Function} fn 関数
* @param {boolean} returnNone 値を返す関数の場合はfalseを設定する。
* @param {boolean} returnNone 値を返す関数の場合はfalseを指定
* @param {boolean} asyncFn Promiseを返す関数かを指定
*/
addFunc (key, josi, fn, returnNone = true) {
this.funclist[key] = { josi, fn, type: 'func', return_none: returnNone }
addFunc (key, josi, fn, returnNone = true, asyncFn = false) {
this.funclist[key] = { josi, fn, type: 'func', return_none: returnNone, asyncFn }
this.pluginFunclist[key] = cloneAsJSON(this.funclist[key])
this.__varslist[0][key] = fn
}
Expand Down
2 changes: 1 addition & 1 deletion src/nako_from_dncl.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function isIndentSyntaxEnabled(src) {
const keywords = DNCL_KEYWORDS
const lines = src.split('\n', 30)
for (const line of lines) {
const line2 = line.replace('!', '!')
const line2 = line.replace(/(|💡)/, '!')
if (keywords.indexOf(line2) >= 0) {
return true
}
Expand Down
Loading

0 comments on commit 2a828b5

Please # to comment.