Linux ns1.utparral.edu.mx 6.8.0-79-generic #79~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 15 16:54:53 UTC 2 x86_64
Apache/2.4.58 (Unix) OpenSSL/1.1.1w PHP/8.2.12 mod_perl/2.0.12 Perl/v5.34.1
: 10.10.1.9 | : 10.10.1.254
Cant Read [ /etc/named.conf ]
daemon
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
README
+ Create Folder
+ Create File
/
usr /
share /
guile /
2.2 /
language /
elisp /
[ HOME SHELL ]
Name
Size
Permission
Action
runtime
[ DIR ]
drwxr-xr-x
bindings.scm
3.88
KB
-rw-r--r--
boot.el
16.69
KB
-rw-r--r--
compile-tree-il.scm
28.17
KB
-rw-r--r--
falias.scm
1.51
KB
-rw-r--r--
lexer.scm
17.28
KB
-rw-r--r--
parser.scm
8.32
KB
-rw-r--r--
runtime.scm
5.16
KB
-rw-r--r--
spec.scm
1.72
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : bindings.scm
;;; Guile Emacs Lisp ;;; Copyright (C) 2009, 2010 Free Software Foundation, Inc. ;;; ;;; This library is free software; you can redistribute it and/or ;;; modify it under the terms of the GNU Lesser General Public ;;; License as published by the Free Software Foundation; either ;;; version 3 of the License, or (at your option) any later version. ;;; ;;; This library is distributed in the hope that it will be useful, ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ;;; Lesser General Public License for more details. ;;; ;;; You should have received a copy of the GNU Lesser General Public ;;; License along with this library; if not, write to the Free Software ;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA ;;; Code: (define-module (language elisp bindings) #:use-module (srfi srfi-1) #:use-module (srfi srfi-8) #:use-module (srfi srfi-9) #:use-module (srfi srfi-26) #:export (make-bindings with-lexical-bindings with-dynamic-bindings with-function-bindings get-lexical-binding get-function-binding)) ;;; This module defines routines to handle analysis of symbol bindings ;;; used during elisp compilation. This data allows to collect the ;;; symbols, for which globals need to be created, or mark certain ;;; symbols as lexically bound. ;;; ;;; The lexical bindings of symbols are stored in a hash-table that ;;; associates symbols to fluids; those fluids are used in the ;;; with-lexical-binding and with-dynamic-binding routines to associate ;;; symbols to different bindings over a dynamic extent. ;;; Record type used to hold the data necessary. (define-record-type bindings (%make-bindings lexical-bindings function-bindings) bindings? (lexical-bindings lexical-bindings) (function-bindings function-bindings)) ;;; Construct an 'empty' instance of the bindings data structure to be ;;; used at the start of a fresh compilation. (define (make-bindings) (%make-bindings (make-hash-table) (make-hash-table))) ;;; Get the current lexical binding (gensym it should refer to in the ;;; current scope) for a symbol or #f if it is dynamically bound. (define (get-lexical-binding bindings sym) (let* ((lex (lexical-bindings bindings)) (slot (hash-ref lex sym #f))) (if slot (fluid-ref slot) #f))) (define (get-function-binding bindings symbol) (and=> (hash-ref (function-bindings bindings) symbol) fluid-ref)) ;;; Establish a binding or mark a symbol as dynamically bound for the ;;; extent of calling proc. (define (with-symbol-bindings bindings syms targets proc) (if (or (not (list? syms)) (not (and-map symbol? syms))) (error "can't bind non-symbols" syms)) (let ((lex (lexical-bindings bindings))) (for-each (lambda (sym) (if (not (hash-ref lex sym)) (hash-set! lex sym (make-fluid)))) syms) (with-fluids* (map (lambda (sym) (hash-ref lex sym)) syms) targets proc))) (define (with-lexical-bindings bindings syms targets proc) (if (or (not (list? targets)) (not (and-map symbol? targets))) (error "invalid targets for lexical binding" targets) (with-symbol-bindings bindings syms targets proc))) (define (with-dynamic-bindings bindings syms proc) (with-symbol-bindings bindings syms (map (lambda (el) #f) syms) proc)) (define (with-function-bindings bindings symbols gensyms thunk) (let ((fb (function-bindings bindings))) (for-each (lambda (symbol) (if (not (hash-ref fb symbol)) (hash-set! fb symbol (make-fluid)))) symbols) (with-fluids* (map (cut hash-ref fb <>) symbols) gensyms thunk)))
Close