Skip to content

Commit c8c7502

Browse files
committed
Add some time functions
1 parent b5070df commit c8c7502

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed

src/Fable.Python.fsproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
<Compile Include="stdlib/Os.fs" />
1717
<Compile Include="stdlib/Queue.fs" />
1818
<Compile Include="stdlib/Sys.fs" />
19+
<Compile Include="stdlib/Time.fs" />
1920
<Compile Include="stdlib/TkInter.fs" />
2021

2122
<Compile Include="cognite-sdk/CogniteSdk.fs" />

src/stdlib/Time.fs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
module Fable.Python.Time
2+
3+
open Fable.Core
4+
5+
// fsharplint:disable MemberNames
6+
7+
type IExports =
8+
abstract altzone : int
9+
abstract ctime : unit -> string
10+
abstract ctime : float -> string
11+
abstract dayligth : int
12+
abstract monotonic : unit -> float
13+
abstract perf_counter : unit -> float
14+
abstract process_time : unit -> float
15+
abstract sleep : secs: float -> unit
16+
abstract time : unit -> float
17+
abstract timezone : int
18+
abstract tzname : string * string
19+
20+
/// Time access and conversions
21+
[<ImportAll("time")>]
22+
let time: IExports = nativeOnly

0 commit comments

Comments
 (0)