Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate from SnoopPrecompile to PrecompileTools #22

Merged
merged 1 commit into from
May 23, 2023
Merged
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
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
DocumenterTools = "35a29f4d-8980-5a13-9543-d66fff28ecb8"
GadgetIO = "826b50da-1eb7-48f3-bd4b-d2350582c309"
Roots = "f2b01f46-fcfa-551c-844a-d8ac1e96c665"
SnoopPrecompile = "66db9d55-30c0-4569-8b51-7e840670fc0c"
PrecompileTools = "aea7be01-6a6a-4083-8856-8a6e6704d82a"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"
UnitfulAstro = "6112ee07-acf9-5e0f-b108-d242c714bf9f"
Expand All @@ -20,7 +20,7 @@ Documenter = "0.25, 0.26, 0.27"
DocumenterTools = "0.1"
GadgetIO = "0.6, 0.7"
Roots = "1, 2"
SnoopPrecompile = "1"
PrecompileTools = "1"
Unitful = "1"
UnitfulAstro = "1"
julia = "1.6"
6 changes: 3 additions & 3 deletions src/GadgetUnits.jl
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ module GadgetUnits
mJy_to_W


using SnoopPrecompile # this is a small dependency
using PrecompileTools # this is a small dependency

@precompile_setup begin
@setup_workload begin
# Putting some things in `setup` can reduce the size of the
# precompile file and potentially make loading faster.

Expand All @@ -35,7 +35,7 @@ module GadgetUnits
Int32(0), Int32(0), Int32(3), 0.0f0,
Int32[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0])

@precompile_all_calls begin
@compile_workload begin
# all calls in this block will be precompiled, regardless of whether
# they belong to your package or not (on Julia 1.8 and higher)

Expand Down