/* * Copyright 2026 Flix Authors * * Use of this source code is governed by the Apache 2.0 license * that can be found in the LICENSE.md file. */////// Effect for checking whether a file is executable, and its functions.///pubmod Fs.IsExecutable {use Fs.FilePermission////// Effect for checking whether a file is executable.////// Use the `IsExecutable.runWithFilePermission` handler.///pubeffIsExecutable {////// Returns `true` if the given file `f` is executable.///defisExecutable(f: String): Result[IoError, Bool] }////// Handles the `IsExecutable` effect of the given function `f` using the `FilePermission` effect.///pubdefrunWithFilePermission(f: Unit -> a \ ef): a \ (ef - IsExecutable) + FilePermission =run { f() } withhandlerIsExecutable {defisExecutable(filename, k) = k(Fs.FilePermission.isExecutable(filename)) }}