;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\302\303\304\305\306\307\310\301\311\312& \210\313\314\315\316\317DD\320\310\303\321\322\311\323& \210\313\324\315\316\325DD\326\310\303\327\330\321\331\311\332& \210\313\333\315\316\334DD\335\321\336\310\303\311\337& \210\313\340\315\316\341DD\342\310\303\321\343\311\344& \210\313\345\315\316\346DD\347\310\303\321\343\311\350& \210\313\351\315\316\352DD\353\310\303\321\343\311\354& \210\313\355\315\316\356DD\357\310\303\321\343\311\360& \210\313\361\315\316\362DD\363\310\303\321\364\327\330\311\365& \210\313\366\315\316\367DD\370\310\303\321\343\311\371& \210\313\372\315\316\373DD\374\310\303\321\364\327\330\311\375& \210\313\376\315\316\377DD\201@\310\303\321\343\311\201A& \210\313\201B\315\316\201CDD\201D\310\303\321\364\311\201E& \210\313\201F\315\316\201GDD\201H\310\303\321\364\327\330\311\201I& \210\313\201J\315\316\201KDD\201L\310\303\321\343\311\201M& \210\313\201N\315\316\201ODD\201P\310\303\321\343\311\201Q& \210\313\201R\315\316\201SDD\201T\310\303\321\343\311\201U& \210\313\201V\315\316\201WDD\201X\310\303\321\343\311\201Y& \210\313\201Z\315\316\201[DD\201\\\310\303\321\343\311\201]& \210\313\201^\315\316\201_DD\201`\310\303\321\343\327\330& \207" [require lsp-mode custom-declare-group lsp-fsharp nil "LSP support for the F# Programming Language, using the FsharpAutoComplete server." :link (url-link "https://github.com/fsharp/FsAutoComplete") :group :package-version (lsp-mode . "6.1") custom-declare-variable lsp-fsharp-server-runtime funcall function #[0 "\300\207" [net-core] 1] "The .NET runtime to use." :type (choice (const :tag "Use .Net Core" net-core) (const :tag "Use Mono" mono) (const :tag "Use .Net Framework" net-framework)) (lsp-mode . "6.1") lsp-fsharp-server-install-dir #[0 "\301\302\"\207" [lsp-server-install-dir f-join "fsautocomplete/"] 3] "Install directory for fsautocomplete server.\nThe slash is expected at the end." :risky t directory (lsp-mode . "6.1") lsp-fsharp-server-args #[0 "\300\207" [nil] 1] "Extra arguments for the F# language server." (repeat string) (lsp-mode . "6.1") lsp-fsharp-keywords-autocomplete #[0 "\300\207" [t] 1] "Provides keywords in autocomplete list." bool (lsp-mode . "6.2") lsp-fsharp-external-autocomplete #[0 "\300\207" [nil] 1] "Provides autocompletion for symbols from not opened namespaces/modules;\ninserts open on accept." (lsp-mode . "6.2") lsp-fsharp-linter #[0 "\300\207" [t] 1] "Enables FSharpLint integration, provides additional warnings and code\naction fixes." (lsp-mode . "6.2") lsp-fsharp-union-case-stub-generation #[0 "\300\207" [t] 1] "Enables a code action to generate pattern matching cases." (lsp-mode . "6.2") lsp-fsharp-union-case-stub-generation-body #[0 "\300\207" [#1="failwith \"Not Implemented\""] 1 #1#] "Defines dummy body used by pattern matching generator." string (lsp-mode . "6.2") lsp-fsharp-record-stub-generation #[0 "\300\207" [t] 1] "Enables code action to generate record stub." (lsp-mode . "6.2") lsp-fsharp-record-stub-generation-body #[0 "\300\207" [#2="failwith \"Not Implemented\""] 1 #2#] "Defines dummy body used by record stub generator." (lsp-mode . "6.2") lsp-fsharp-interface-stub-generation #[0 "\300\207" [t] 1] "Enables code action to generate an interface stub." (lsp-mode . "6.2") lsp-fsharp-interface-stub-generation-object-identifier #[0 "\300\207" [#3="this"] 1 #3#] "Defines object identifier used by interface stub generator,\ne.g. `this' or `self'." (lsp-mode . "6.2") lsp-fsharp-interface-stub-generation-method-body #[0 "\300\207" [#4="failwith \"Not Implemented\""] 1 #4#] "Defines dummy body used by interface stub generator." (lsp-mode . "6.2") lsp-fsharp-unused-opens-analyzer #[0 "\300\207" [t] 1] "Enables unused open detection." (lsp-mode . "6.2") lsp-fsharp-unused-declarations-analyzer #[0 "\300\207" [t] 1] "Enables unused symbol detection." (lsp-mode . "6.2") lsp-fsharp-simplify-name-analyzer #[0 "\300\207" [nil] 1] "Enables simplify name analyzer and remove redundant qualifier quick fix." (lsp-mode . "6.2") lsp-fsharp-resolve-namespaces #[0 "\300\207" [t] 1] "Enables resolve namespace quick fix; adds `open' if symbol is from not yet\nopened module/namespace." (lsp-mode . "6.2") lsp-fsharp-enable-reference-code-lens #[0 "\300\207" [t] 1] "Enables reference count code lenses.\nIt is recommended to disable if `--backgorund-service-enabled' is not used." (lsp-mode . "6.2") lsp-fsharp-auto-workspace-init #[0 "\300\207" [nil] 1] "Enable automatic workspace initialization.\nDo note that this can cause unexpected or challenging behaviors, as solutions\nwith test projects are not autoloaded by FSharpAutoComplete."] 12) #@82 Get the command required to run fsautocomplete based off of the current runtime. (defalias 'lsp-fsharp--fsac-runtime-cmd #[0 "\301\267\202\f\302\207\303\207\304\207\304\207" [lsp-fsharp-server-runtime #s(hash-table size 3 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (net-core 6 mono 8 net-framework 10)) "dotnet" "mono" nil] 2 (#$ . 4740)]) #@44 The location of fsautocomplete executable. (defalias 'lsp-fsharp--fsac-cmd #[0 "\302=\203\n\303\202 \304\305\306P \"\207" [lsp-fsharp-server-runtime lsp-fsharp-server-install-dir net-core ".dll" ".exe" expand-file-name "fsautocomplete"] 4 (#$ . 5109)]) #@52 Return latest version from LST (if any). (fn LST) (defalias 'lsp-fsharp--version-list-latest #[257 "\300\301\302\303\304\305\"\"\"@\207" [-sort #[514 "\300\301\302O\301\302O\"?\207" [version<= 1 nil] 7 "\n\n(fn A B)"] -filter #[257 "\211G\300V\207" [0] 3 "\n\n(fn X)"] -map #[257 "\300\301\"@\207" [s-split " "] 4 "\n\n(fn X)"]] 8 (#$ . 5372)]) #@45 Retrieve and parse JSON from URL. (fn URL) (defalias 'lsp-fsharp--fetch-json #[257 "\301\302\303\"r\211q\210\304\305\"\216\306!\210\307\310 +\207" [json-false generate-new-buffer " *temp*" t make-closure #[0 "\301\300!\205 \302\300!\207" [V0 buffer-name kill-buffer] 2] url-insert-file-contents :false json-read] 5 (#$ . 5729)]) #@60 Return latest version of the server available from github. (defalias 'lsp-fsharp--latest-version-from-github #[0 "\300\301\302\303\304!\"!\207" [lsp-fsharp--version-list-latest seq-map #[257 "\300\301\236A!\207" [s-trim name] 4 "\n\n(fn ELT)"] lsp-fsharp--fetch-json "https://api.github.com/repos/fsharp/FsAutoComplete/releases"] 5 (#$ . 6069)]) #@113 Return url for .zip file to download for given VERSION, depending on `lsp-fsharp-server-runtime'. (fn VERSION) (defalias 'lsp-fsharp--server-download-url #[257 "\301\302\303=\203 \304\202\305R\207" [lsp-fsharp-server-runtime "https://github.com/fsharp/FsAutoComplete/releases/download/" "/" net-core "fsautocomplete.netcore.zip" "fsautocomplete.zip"] 6 (#$ . 6423)]) #@146 Download the latest version of fsautocomplete and extract it to `lsp-fsharp-server-install-dir'. (fn CLIENT CALLBACK ERROR-CALLBACK UPDATE\=\?) (defalias 'lsp-fsharp--fsac-install #[1028 "\301\302\303\304#\305!\306\307!\203\310\311$\202+\306\312!\203%\310\313#\202+\314\310\315\"!\316 \317!\320\321#\210\322!\210\322\310\323\324 \325 #!\210 \207" [lsp-fsharp-server-install-dir make-temp-file "fsautocomplete" nil ".zip" expand-file-name executable-find "unzip" format "mkdir -p %s && unzip -qq %s -d %s" "powershell" "powershell -noprofile -noninteractive -nologo -ex bypass Expand-Archive -path '%s' -dest '%s'" user-error "Unable to unzip server - file %s cannot be extracted, please extract it manually" lsp-fsharp--latest-version-from-github lsp-fsharp--server-download-url url-copy-file t shell-command "%s %s --version" lsp-fsharp--fsac-runtime-cmd lsp-fsharp--fsac-cmd] 14 (#$ . 6803)]) #@46 Update fsautocomplete to the latest version. (defalias 'lsp-fsharp-update-fsac #[0 "\301!\302\303\"\210\304\305\306\307\303$\207" [lsp-fsharp-server-install-dir f-expand f-delete t lsp-fsharp--fsac-install nil ignore lsp--error] 6 (#$ . 7724) nil]) #@54 Build the command required to launch fsautocomplete. (defalias 'lsp-fsharp--make-launch-cmd #[0 "\301\302 \303 \304E\"\207" [lsp-fsharp-server-args append lsp-fsharp--fsac-runtime-cmd lsp-fsharp--fsac-cmd "--background-service-enabled"] 4 (#$ . 7981)]) #@64 Get the list of files we need to send to fsharp/workspaceLoad. (defalias 'lsp-fsharp--project-list #[0 "\301\302\303\304 \305BB\"\306\307\310\"\311\203\312\202\313\314\315\316\315&\307\211\317\"\320\"\321\322\"\307\211\317\"\323\"\207" [lsp-use-plists lsp-request "fsharp/workspacePeek" :directory lsp-workspace-root (:deep 10 :excludedDirs ["paket-files" ".git" "packages" "node_modules"]) json-parse-string lsp-get :content :object-type plist hash-table :null-object nil :false-object :Data :Found seq-find #[257 "\300\301\"\302\232\207" [lsp-get :Type "directory"] 4 "\n\n(fn D)"] :Fsprojs] 9 (#$ . 8241)]) #@51 Load all of the provided PROJECTS. (fn PROJECTS) (defalias 'lsp-fsharp--workspace-load #[257 "\300\301\302\303\304\305\306\"\"D\307#\207" [lsp-request-async "fsharp/workspaceLoad" :textDocuments vconcat [] mapcar #[257 "\300D\207" [:uri] 3 "\n\n(fn P)"] #[257 "\300\301!\207" [lsp--info "Workspace Loaded!"] 3 "\n\n(fn _)"]] 9 (#$ . 8868)]) #@118 Default init options to be passed to FSharpAutoComplete, updated conditionally by `lsp-fsharp--make-init-options'. (defvar lsp-fsharp--default-init-options nil (#$ . 9220)) #@22 Init options for F#. (defalias 'lsp-fsharp--make-init-options #[0 " \203\f\302B\211\262\207\207" [lsp-fsharp--default-init-options lsp-fsharp-auto-workspace-init (:AutomaticWorkspaceInit . t)] 3 (#$ . 9401)]) (byte-code "\300\301!\210\302\303\304\305\306\307\"\310\311\312\313\314\315\"\316\317\320#\210\316\321\320#\210\316\322\320#\210\316\323\320#\210\211\262\324\325\326\327\330\331\332\333&!\207" [lsp-register-custom-settings (("FSharp.KeywordsAutocomplete" lsp-fsharp-keywords-autocomplete t) ("FSharp.ExternalAutocomplete" lsp-fsharp-external-autocomplete t) ("FSharp.Linter" lsp-fsharp-linter t) ("FSharp.UnionCaseStubGeneration" lsp-fsharp-union-case-stub-generation t) ("FSharp.UnionCaseStubGenerationBody" lsp-fsharp-union-case-stub-generation-body) ("FSharp.RecordStubGeneration" lsp-fsharp-record-stub-generation t) ("FSharp.RecordStubGenerationBody" lsp-fsharp-record-stub-generation-body) ("FSharp.InterfaceStubGeneration" lsp-fsharp-interface-stub-generation t) ("FSharp.InterfaceStubGenerationObjectIdentifier" lsp-fsharp-interface-stub-generation-object-identifier) ("FSharp.InterfaceStubGenerationMethodBody" lsp-fsharp-interface-stub-generation-method-body) ("FSharp.UnusedOpensAnalyzer" lsp-fsharp-unused-opens-analyzer t) ("FSharp.UnusedDeclarationsAnalyzer" lsp-fsharp-unused-declarations-analyzer t) ("FSharp.SimplifyNameAnalyzer" lsp-fsharp-simplify-name-analyzer t) ("FSharp.ResolveNamespaces" lsp-fsharp-resolve-namespaces t) ("FSharp.EnableReferenceCodeLens" lsp-fsharp-enable-reference-code-lens t)) lsp-register-client make-lsp-client :new-connection lsp-stdio-connection lsp-fsharp--make-launch-cmd #[0 "\300\301 !\207" [f-exists\? lsp-fsharp--fsac-cmd] 2] :major-modes (fsharp-mode) :notification-handlers make-hash-table :test equal puthash "fsharp/notifyCancel" ignore "fsharp/notifyWorkspace" "fsharp/fileParsed" "fsharp/notifyWorkspacePeek" :initialization-options lsp-fsharp--make-init-options :initialized-fn #[257 "\211\301\302\303!!\210\304\305 !)\207" [lsp--cur-workspace lsp--set-configuration lsp-configuration-section "fsharp" lsp-fsharp--workspace-load lsp-fsharp--project-list] 4 "\n\n(fn WORKSPACE)"] :server-id fsac :download-server-fn lsp-fsharp--fsac-install] 16) (defconst lsp-fsharp-plist-value-when-compiled nil) (provide 'lsp-fsharp)