Skip to content

Commit

Permalink
⅄ trunk → fix-merge-bug
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchellwrosen committed Jun 20, 2024
2 parents a021eb4 + e354912 commit d842e80
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
- uses: actions/checkout@v4
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
uses: tj-actions/changed-files@v44
with:
# globs copied from default settings for run-ormolu
files: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ormolu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: create pull request with formatting changes
uses: peter-evans/create-pull-request@v6
with:
commit_message: automatically run ormolu
commit-message: automatically run ormolu
branch: autoformat/${{github.ref_name}}
# branch_suffix: random
branch-suffix: short-commit-hash
title: format `${{github.ref_name}}` with ormolu ${{env.ormolu_version}}
10 changes: 9 additions & 1 deletion parser-typechecker/src/Unison/Runtime/Builtin.hs
Original file line number Diff line number Diff line change
Expand Up @@ -2599,8 +2599,16 @@ declareForeigns = do

declareForeign Tracked "IO.kill.impl.v3" boxToEF0 $ mkForeignIOF killThread

let mx :: Word64
mx = fromIntegral (maxBound :: Int)

customDelay :: Word64 -> IO ()
customDelay n
| n < mx = threadDelay (fromIntegral n)
| otherwise = threadDelay maxBound >> customDelay (n - mx)

declareForeign Tracked "IO.delay.impl.v3" natToEFUnit $
mkForeignIOF threadDelay
mkForeignIOF customDelay

declareForeign Tracked "IO.stdHandle" standard'handle
. mkForeign
Expand Down

0 comments on commit d842e80

Please sign in to comment.