Skip to content

Commit

Permalink
Revert "Remove Preferences support"
Browse files Browse the repository at this point in the history
This reverts commit 65c10b6.
  • Loading branch information
mofeing committed May 5, 2024
1 parent 65c10b6 commit 206351d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ version = "0.1.0"
CEnum = "fa961155-64e5-5f13-b03f-caf6b980ea82"
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
MLIR_jll = "a70bccb4-a5c0-5e2e-a329-e731972457e8"
Preferences = "21216c6a-2e73-6563-6e65-726566657250"
ScopedValues = "7e506255-f358-4e82-b7e4-beb19740aa63"

[compat]
CEnum = "0.4"
MLIR_jll = "14,15,16"
Preferences = "1"
ScopedValues = "1"
julia = "1.9"
5 changes: 3 additions & 2 deletions src/MLIR.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
module MLIR

using Preferences
using ScopedValues
import MLIR_jll

const MLIR_VERSION = ScopedValue(Base.libllvm_version)
const MLIR_C_PATH = ScopedValue(MLIR_jll.mlir_c)
const MLIR_VERSION = ScopedValue(VersionNumber(@load_preference("MLIR_VERSION", Base.libllvm_version_string)))
const MLIR_C_PATH = ScopedValue(@load_preference("MLIR_C_PATH", MLIR_jll.mlir_c))

struct MLIRException <: Exception
msg::String
Expand Down

0 comments on commit 206351d

Please sign in to comment.