Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
qianlong66
uni-app
提交
5a0742b1
U
uni-app
项目概览
qianlong66
/
uni-app
与 Fork 源项目一致
Fork自
DCloud / uni-app
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
5a0742b1
编写于
9月 16, 2022
作者:
fxy060608
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
wip(uts): compiler
上级
b40c9ee2
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
16 addition
and
2 deletion
+16
-2
packages/playground/uts/uni_modules/test-uniplugin/app-android/index.uts
...ound/uts/uni_modules/test-uniplugin/app-android/index.uts
+6
-0
packages/playground/uts/uni_modules/test-uniplugin/app-ios/index.uts
...ayground/uts/uni_modules/test-uniplugin/app-ios/index.uts
+6
-0
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-android/index.kt
.../dist/app/uni_modules/test-uniplugin/app-android/index.kt
+1
-0
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-android/index.kt.map
...t/app/uni_modules/test-uniplugin/app-android/index.kt.map
+1
-1
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-ios/index.swift
...e/dist/app/uni_modules/test-uniplugin/app-ios/index.swift
+1
-0
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-ios/index.swift.map
...st/app/uni_modules/test-uniplugin/app-ios/index.swift.map
+1
-1
packages/uts-darwin-arm64/uts.darwin-arm64.node
packages/uts-darwin-arm64/uts.darwin-arm64.node
+0
-0
packages/uts-darwin-x64/uts.darwin-x64.node
packages/uts-darwin-x64/uts.darwin-x64.node
+0
-0
packages/uts-win32-ia32-msvc/uts.win32-ia32-msvc.node
packages/uts-win32-ia32-msvc/uts.win32-ia32-msvc.node
+0
-0
packages/uts-win32-x64-msvc/uts.win32-x64-msvc.node
packages/uts-win32-x64-msvc/uts.win32-x64-msvc.node
+0
-0
未找到文件。
packages/playground/uts/uni_modules/test-uniplugin/app-android/index.uts
浏览文件 @
5a0742b1
...
...
@@ -29,6 +29,12 @@ export class User implements IUser {
//#ifndef APP-IOS
console.log('ndef ios')
//#endif
//#ifdef APP-ANDROID || APP-IOS
console.log('def android || def ios')
//#endif
//#ifdef MP-WEIXIN
console.log('def weixin')
//#endif
}
register(name: string, callback: () => void) {
Log.info(logo as FrameLayout)
...
...
packages/playground/uts/uni_modules/test-uniplugin/app-ios/index.uts
浏览文件 @
5a0742b1
...
...
@@ -36,6 +36,12 @@ export function test1(callback: () => void) {
//#ifndef APP-IOS
console.log('ndef ios')
//#endif
//#ifdef APP-ANDROID || APP-IOS
console.log('def android || def ios')
//#endif
//#ifdef MP-WEIXIN
console.log('def weixin')
//#endif
}
class Test1 {}
...
...
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-android/index.kt
浏览文件 @
5a0742b1
...
...
@@ -31,6 +31,7 @@ open class User : IUser {
Log
.
info
(
__default
);
console
.
log
(
"def android"
,
" at uni_modules/test-uniplugin/app-android/index.uts:21"
);
console
.
log
(
"ndef ios"
,
" at uni_modules/test-uniplugin/app-android/index.uts:30"
);
console
.
log
(
"def android || def ios"
,
" at uni_modules/test-uniplugin/app-android/index.uts:33"
);
}
override
fun
register
(
name
:
String
,
callback
:
UTSCallback
)
{
Log
.
info
(
__default
as
FrameLayout
);
...
...
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-android/index.kt.map
浏览文件 @
5a0742b1
{"version":3,"sources":["/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/static/logo.png","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/index.uts","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/interface.uts","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/login.uts"],"sourcesContent":["import { getResourcePath } from 'io.dcloud.uts.android'\nexport default getResourcePath('uni_modules/test-uniplugin/static/logo.png')\n ","import Log from 'android.util.Log'\nimport FrameLayout from 'android.widget.FrameLayout'\nimport View from 'android.view.View'\nimport { IUser } from './interface.uts'\nimport { login } from './login.uts'\nimport logo from '../static/logo.png'\n\ntype GetBatteryInfoOptions = {\n success?: (res: UTSJSONObject) => void\n fail?: (res: UTSJSONObject) => void\n complete?: (res: UTSJSONObject) => void\n}\nexport class User implements IUser {\n async login(name: string, pwd: string) {\n setTimeout(() => {\n console.log('timeout')\n }, 1000)\n login(name, pwd)\n Log.info(logo)\n\n console.log('def android')\n\n\n\n\n\n\n\n\n console.log('ndef ios')\n\n }\n register(name: string, callback: () => void) {\n Log.info(logo as FrameLayout)\n }\n test(view: View) {}\n}\nfunction login(name: string, callback: () => void) {}\nexport function register(name: string, callback: () => void) {}\n","export interface IUser {\n register(name: string): void\n}\n","export function login(name: string, pwd: string) {\n console.log('login')\n return { name, pwd }\n}\n"],"names":[],"mappings":";;;AAAA;ACAA,OAAgB,gBAAkB,CAAA;AAClC,OAAwB,0BAA4B,CAAA;AACpD,OAAiB,iBAAmB,CAAA;UCFnB,KAAK;QACpB,QAAQ,CAAC,IAAY,EAAN,MAAM,GAAG,IAAI;;ACDvB,IAAS,KAAK,CAAC,IAAY,EAAN,MAAM,EAAE,GAAW,EAAN,MAAM,iBAAE;IAC/C,OAAO,CAAC,GAAG,CAAC,OAAO,2DAAC;IACpB,OAAO;QAAE,IAAA,IAAI,GAAJ,IAAI;QAAE,IAAA,GAAG,GAAH,GAAG;KAAE,CAAA;AACtB;gBHFe,eAAe,CAAC,4CAA4C,CAAC;ACM/C,WAAxB,qBAAqB;IACxB,SAAA,OAAO,EAAC,WAA8B,SAAA;IACtC,SAAA,IAAI,EAAC,WAA8B,SAAA;IACnC,SAAA,QAAQ,EAAC,WAA8B,SAAA;CACxC;AACM,WAAM,IAAI,GAAY,KAAK;qBAC1B,KAAK,CAAC,IAAY,EAAN,MAAM,EAAE,GAAW,EAAN,MAAM,8CAAE;QACrC,UAAU,CAAC,KAAM;YACf,OAAO,CAAC,GAAG,CAAC,SAAS,4DAAC;QACxB;QAAC,EAAE,IAAI,CAAC;QACR,MAAM,IAAI,EAAE,GAAG,CAAC;QAChB,GAAG,CAAC,IAAI,WAAM;QAEd,OAAO,CAAC,GAAG,CAAC,aAAa,4DAAC;QAS1B,OAAO,CAAC,GAAG,CAAC,UAAU,4DAAC;IAEzB;iBACA,QAAQ,CAAC,IAAY,EAAN,MAAM,EAAE,QAAoB,aAAA,EAAE;QAC3C,GAAG,CAAC,IAAI,cAAS,WAAW,CAAC;IAC/B;aACA,IAAI,CAAC,IAAU,EAAJ,IAAI,EAAE,CAAC;CACnB;AACD,UAAe,IAAY,EAAN,MAAM,EAAE,QAAoB,QAAJ,IAAI,EAAE,CAAC,CAAC;AAC9C,IAAS,QAAQ,CAAC,IAAY,EAAN,MAAM,EAAE,QAAoB,aAAA,EAAE,CAAC,CAAC"}
\ No newline at end of file
{"version":3,"sources":["/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/static/logo.png","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/index.uts","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/interface.uts","/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-android/login.uts"],"sourcesContent":["import { getResourcePath } from 'io.dcloud.uts.android'\nexport default getResourcePath('uni_modules/test-uniplugin/static/logo.png')\n ","import Log from 'android.util.Log'\nimport FrameLayout from 'android.widget.FrameLayout'\nimport View from 'android.view.View'\nimport { IUser } from './interface.uts'\nimport { login } from './login.uts'\nimport logo from '../static/logo.png'\n\ntype GetBatteryInfoOptions = {\n success?: (res: UTSJSONObject) => void\n fail?: (res: UTSJSONObject) => void\n complete?: (res: UTSJSONObject) => void\n}\nexport class User implements IUser {\n async login(name: string, pwd: string) {\n setTimeout(() => {\n console.log('timeout')\n }, 1000)\n login(name, pwd)\n Log.info(logo)\n\n console.log('def android')\n\n\n\n\n\n\n\n\n console.log('ndef ios')\n\n\n console.log('def android || def ios')\n\n\n\n\n }\n register(name: string, callback: () => void) {\n Log.info(logo as FrameLayout)\n }\n test(view: View) {}\n}\nfunction login(name: string, callback: () => void) {}\nexport function register(name: string, callback: () => void) {}\n","export interface IUser {\n register(name: string): void\n}\n","export function login(name: string, pwd: string) {\n console.log('login')\n return { name, pwd }\n}\n"],"names":[],"mappings":";;;AAAA;ACAA,OAAgB,gBAAkB,CAAA;AAClC,OAAwB,0BAA4B,CAAA;AACpD,OAAiB,iBAAmB,CAAA;UCFnB,KAAK;QACpB,QAAQ,CAAC,IAAY,EAAN,MAAM,GAAG,IAAI;;ACDvB,IAAS,KAAK,CAAC,IAAY,EAAN,MAAM,EAAE,GAAW,EAAN,MAAM,iBAAE;IAC/C,OAAO,CAAC,GAAG,CAAC,OAAO,2DAAC;IACpB,OAAO;QAAE,IAAA,IAAI,GAAJ,IAAI;QAAE,IAAA,GAAG,GAAH,GAAG;KAAE,CAAA;AACtB;gBHFe,eAAe,CAAC,4CAA4C,CAAC;ACM/C,WAAxB,qBAAqB;IACxB,SAAA,OAAO,EAAC,WAA8B,SAAA;IACtC,SAAA,IAAI,EAAC,WAA8B,SAAA;IACnC,SAAA,QAAQ,EAAC,WAA8B,SAAA;CACxC;AACM,WAAM,IAAI,GAAY,KAAK;qBAC1B,KAAK,CAAC,IAAY,EAAN,MAAM,EAAE,GAAW,EAAN,MAAM,8CAAE;QACrC,UAAU,CAAC,KAAM;YACf,OAAO,CAAC,GAAG,CAAC,SAAS,4DAAC;QACxB;QAAC,EAAE,IAAI,CAAC;QACR,MAAM,IAAI,EAAE,GAAG,CAAC;QAChB,GAAG,CAAC,IAAI,WAAM;QAEd,OAAO,CAAC,GAAG,CAAC,aAAa,4DAAC;QAS1B,OAAO,CAAC,GAAG,CAAC,UAAU,4DAAC;QAGvB,OAAO,CAAC,GAAG,CAAC,wBAAwB,4DAAC;IAKvC;iBACA,QAAQ,CAAC,IAAY,EAAN,MAAM,EAAE,QAAoB,aAAA,EAAE;QAC3C,GAAG,CAAC,IAAI,cAAS,WAAW,CAAC;IAC/B;aACA,IAAI,CAAC,IAAU,EAAJ,IAAI,EAAE,CAAC;CACnB;AACD,UAAe,IAAY,EAAN,MAAM,EAAE,QAAoB,QAAJ,IAAI,EAAE,CAAC,CAAC;AAC9C,IAAS,QAAQ,CAAC,IAAY,EAAN,MAAM,EAAE,QAAoB,aAAA,EAAE,CAAC,CAAC"}
\ No newline at end of file
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-ios/index.swift
浏览文件 @
5a0742b1
...
...
@@ -36,5 +36,6 @@ class IndexSwift : NSObject {
console
.
log
(
"test1"
,
" at uni_modules/test-uniplugin/app-ios/index.uts:26"
);
console
.
log
(
"def ios"
,
" at uni_modules/test-uniplugin/app-ios/index.uts:31"
);
console
.
log
(
"ndef android"
,
" at uni_modules/test-uniplugin/app-ios/index.uts:34"
);
console
.
log
(
"def android || def ios"
,
" at uni_modules/test-uniplugin/app-ios/index.uts:40"
);
}
}
packages/playground/uts/unpackage/dist/app/uni_modules/test-uniplugin/app-ios/index.swift.map
浏览文件 @
5a0742b1
{"version":3,"sources":["/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-ios/index.uts"],"sourcesContent":["import { UIDevice } from 'UIKit'\n\ntype GetBatteryInfoOptions = {\n name: string\n pwd: number\n success?: (res: UTSJSONObject) => void\n fail?: (res: UTSJSONObject) => void\n complete?: (res: UTSJSONObject) => void\n}\n\nexport default function getBatteryInfo(options: GetBatteryInfoOptions) {\n const res = {\n errMsg: 'getBatteryInfo:ok',\n level: UIDevice.current.batteryLevel * 100,\n isCharging: UIDevice.current.batteryState == UIDevice.BatteryState.charging,\n }\n if (options.success != null) {\n options.success!(res)\n }\n if (options.complete != null) {\n options.complete!(res)\n }\n}\n\nexport function test1(callback: () => void) {\n console.log('test1')\n\n\n\n\n console.log('def ios')\n\n\n console.log('ndef android')\n\n\n\n\n}\n\nclass Test1 {}\nexport class Test {\n constructor() {\n new Test1()\n }\n}\n"],"names":[],"mappings":";AAAA;AAEA;;AAA6B,MAAxB,qBAAqB;IACxB,WAAA,IAAI,EAAE,MAAM,EAAA;IACZ,WAAA,GAAG,EAAE,QAAM,EAAA;IACX,WAAA,OAAO,EAAC,WAA8B,EAAA;IACtC,WAAA,IAAI,EAAC,WAA8B,EAAA;IACnC,WAAA,QAAQ,EAAC,WAA8B,EAAA;CACxC;AAgCD,MAAM,KAAK;CAAG;AACP,MAAM,IAAI;IACf,aAAc;QACZ,AAAI,KAAK,EAAE;IACb;CACD;;;;uBAnCuB,cAAc,CAAC,EAAA,OAA8B,EAArB,qBAAqB,EAAE;QACrE,IAAM,GAAG,GAAG;YACV,CAAA,MAAM,GAAE,mBAAmB;YAC3B,CAAA,KAAK,GAAE,QAAQ,CAAC,OAAO,CAAC,YAAY,GAAG,GAAG;YAC1C,CAAA,UAAU,GAAE,QAAQ,CAAC,OAAO,CAAC,YAAY,IAAI,QAAQ,CAAC,YAAY,CAAC,QAAQ;0BAC5E;QACD,IAAI,OAAO,CAAC,OAAO,IAAI,GAAI;YACzB,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC;;QAEvB,IAAI,OAAO,CAAC,QAAQ,IAAI,GAAI;YAC1B,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC;;IAE1B;uBAEgB,KAAK,CAAC,EAAA,QAAoB,aAAA,EAAE;QAC1C,OAAO,CAAC,GAAG,CAAC,OAAO,wDAAC;QAKpB,OAAO,CAAC,GAAG,CAAC,SAAS,wDAAC;QAGtB,OAAO,CAAC,GAAG,CAAC,cAAc,wDAAC;IAK7B"}
\ No newline at end of file
{"version":3,"sources":["/Users/fxy/Projects/GitHub/uni-app/uni-app-next/packages/playground/uts/uni_modules/test-uniplugin/app-ios/index.uts"],"sourcesContent":["import { UIDevice } from 'UIKit'\n\ntype GetBatteryInfoOptions = {\n name: string\n pwd: number\n success?: (res: UTSJSONObject) => void\n fail?: (res: UTSJSONObject) => void\n complete?: (res: UTSJSONObject) => void\n}\n\nexport default function getBatteryInfo(options: GetBatteryInfoOptions) {\n const res = {\n errMsg: 'getBatteryInfo:ok',\n level: UIDevice.current.batteryLevel * 100,\n isCharging: UIDevice.current.batteryState == UIDevice.BatteryState.charging,\n }\n if (options.success != null) {\n options.success!(res)\n }\n if (options.complete != null) {\n options.complete!(res)\n }\n}\n\nexport function test1(callback: () => void) {\n console.log('test1')\n\n\n\n\n console.log('def ios')\n\n\n console.log('ndef android')\n\n\n\n\n\n console.log('def android || def ios')\n\n\n\n\n}\n\nclass Test1 {}\nexport class Test {\n constructor() {\n new Test1()\n }\n}\n"],"names":[],"mappings":";AAAA;AAEA;;AAA6B,MAAxB,qBAAqB;IACxB,WAAA,IAAI,EAAE,MAAM,EAAA;IACZ,WAAA,GAAG,EAAE,QAAM,EAAA;IACX,WAAA,OAAO,EAAC,WAA8B,EAAA;IACtC,WAAA,IAAI,EAAC,WAA8B,EAAA;IACnC,WAAA,QAAQ,EAAC,WAA8B,EAAA;CACxC;AAsCD,MAAM,KAAK;CAAG;AACP,MAAM,IAAI;IACf,aAAc;QACZ,AAAI,KAAK,EAAE;IACb;CACD;;;;uBAzCuB,cAAc,CAAC,EAAA,OAA8B,EAArB,qBAAqB,EAAE;QACrE,IAAM,GAAG,GAAG;YACV,CAAA,MAAM,GAAE,mBAAmB;YAC3B,CAAA,KAAK,GAAE,QAAQ,CAAC,OAAO,CAAC,YAAY,GAAG,GAAG;YAC1C,CAAA,UAAU,GAAE,QAAQ,CAAC,OAAO,CAAC,YAAY,IAAI,QAAQ,CAAC,YAAY,CAAC,QAAQ;0BAC5E;QACD,IAAI,OAAO,CAAC,OAAO,IAAI,GAAI;YACzB,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC;;QAEvB,IAAI,OAAO,CAAC,QAAQ,IAAI,GAAI;YAC1B,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC;;IAE1B;uBAEgB,KAAK,CAAC,EAAA,QAAoB,aAAA,EAAE;QAC1C,OAAO,CAAC,GAAG,CAAC,OAAO,wDAAC;QAKpB,OAAO,CAAC,GAAG,CAAC,SAAS,wDAAC;QAGtB,OAAO,CAAC,GAAG,CAAC,cAAc,wDAAC;QAM3B,OAAO,CAAC,GAAG,CAAC,wBAAwB,wDAAC;IAKvC"}
\ No newline at end of file
packages/uts-darwin-arm64/uts.darwin-arm64.node
浏览文件 @
5a0742b1
无法预览此类型文件
packages/uts-darwin-x64/uts.darwin-x64.node
浏览文件 @
5a0742b1
无法预览此类型文件
packages/uts-win32-ia32-msvc/uts.win32-ia32-msvc.node
浏览文件 @
5a0742b1
无法预览此类型文件
packages/uts-win32-x64-msvc/uts.win32-x64-msvc.node
浏览文件 @
5a0742b1
无法预览此类型文件
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录