* guile-gnome, devel: removes guile-1.8 specific code and dependency
@ 2014-10-07 22:54 David Pirotte
0 siblings, 0 replies; only message in thread
From: David Pirotte @ 2014-10-07 22:54 UTC (permalink / raw)
To: guile-devel
[-- Attachment #1: Type: text/plain, Size: 134 bytes --]
Hello,
guile-gnome
devel: removes guile-1.8 specific code and dependency
Attached, patch review welcome.
Happy hacking,
David
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0015-removes-guile-1.8-specific-code-and-dependency.patch --]
[-- Type: text/x-patch, Size: 5499 bytes --]
From 681b47b766d0c2235fe396e002fcce5a03c80a17 Mon Sep 17 00:00:00 2001
From: David PIROTTE <david@altosw.be>
Date: Tue, 7 Oct 2014 19:48:33 -0300
Subject: [PATCH] removes guile-1.8 specific code and dependency
* configure.ac: 1.8 removed from the supported guile version list
* glib/gnome/gobject/utils.scm:
* glib/gnome/gw/support/gtk-doc.scm:
* glib/gnome/gw/support/modules.scm:
* glib/gnome/gw/support/slib.scm: code related to the support of guile
versions prior to guile 2 has been removed. In addition, as
when/unless macros have been introduced in guile 2.0.5, its
definition has also been removed.
---
configure.ac | 2 +-
glib/gnome/gobject/utils.scm | 40 +++++++++------------------------------
glib/gnome/gw/support/gtk-doc.scm | 6 ------
glib/gnome/gw/support/modules.scm | 10 ----------
glib/gnome/gw/support/slib.scm | 12 +++---------
5 files changed, 13 insertions(+), 57 deletions(-)
diff --git a/configure.ac b/configure.ac
index dcb1487..0fa5e2c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -77,7 +77,7 @@ AC_HELP_STRING([--disable-deprecated],[Disable wrapping of functions deprecated
# Check for Guile
#
GUILE_EFFECTIVE_VERSION=no
-all_versions="2.2 2.0 1.8"
+all_versions="2.2 2.0"
for v in $all_versions; do
if test $GUILE_EFFECTIVE_VERSION = no; then
AC_MSG_NOTICE([checking for Guile $v.x])
diff --git a/glib/gnome/gobject/utils.scm b/glib/gnome/gobject/utils.scm
index 7a36bbb..5383a36 100644
--- a/glib/gnome/gobject/utils.scm
+++ b/glib/gnome/gobject/utils.scm
@@ -41,8 +41,7 @@
;;; {Miscellaneous}
;;;
-(cond-expand
- (guile-2
+(eval-when (expand load eval)
(define-syntax define-macro-with-docs
(lambda (x)
"Define a defmacro with documentation."
@@ -50,14 +49,6 @@
((_ (f . args) doc b0 b* ...)
#'(define-macro (f . args)
doc b0 b* ...))))))
- (else
- (define-macro (define-macro-with-docs form docs . body)
- `(begin
- (define-macro ,form ,@body)
- (set-object-property! ,(car form) 'documentation ,docs)))
- (define-macro (unless test . body)
- `(if (not ,test) (begin ,@body)))
- (export unless)))
(define-macro-with-docs (define-with-docs name docs val)
"Define @var{name} as @var{val}, documenting the value with
@@ -202,24 +193,11 @@ Uses @code{gtype-name->scheme-name}."
(resolve-interface ',mod)))
args))))
-(define-macro (unless test . body)
- `(if (not ,test) (begin ,@body)))
-
-(cond-expand
- (guile-2
- (define-macro (with-accessors names . body)
- `(let (,@(map (lambda (name)
- ;; Ew, fixme.
- `(,name (make-procedure-with-setter
- (lambda (x) (slot-ref x ',name))
- (lambda (x y) (slot-set! x ',name y)))))
- names))
- ,@body)))
- (else
- (define-macro (with-accessors names . body)
- `(let (,@(map (lambda (name)
- `(,name ,(make-procedure-with-setter
- (lambda (x) (slot-ref x name))
- (lambda (x y) (slot-set! x name y)))))
- names))
- ,@body))))
+(define-macro (with-accessors names . body)
+ `(let (,@(map (lambda (name)
+ ;; Ew, fixme.
+ `(,name (make-procedure-with-setter
+ (lambda (x) (slot-ref x ',name))
+ (lambda (x y) (slot-set! x ',name y)))))
+ names))
+ ,@body))
diff --git a/glib/gnome/gw/support/gtk-doc.scm b/glib/gnome/gw/support/gtk-doc.scm
index 463bfc8..4accfd9 100644
--- a/glib/gnome/gw/support/gtk-doc.scm
+++ b/glib/gnome/gw/support/gtk-doc.scm
@@ -138,13 +138,7 @@
;; is
(for-each
(lambda (pair)
- (cond-expand
- (guile-2
(define-parsed-entity! (car pair) (cdr pair)))
- (else
- (set! ssax:predefined-parsed-entities
- (assoc-set! ssax:predefined-parsed-entities
- (car pair) (cdr pair))))))
'((nbsp . " ")
(percnt . "%")
(oacute . "ó")
diff --git a/glib/gnome/gw/support/modules.scm b/glib/gnome/gw/support/modules.scm
index 7ed28d0..4ebbcff 100644
--- a/glib/gnome/gw/support/modules.scm
+++ b/glib/gnome/gw/support/modules.scm
@@ -30,16 +30,6 @@
#:export-syntax (re-export-modules)
#:export (export-all-lazy!))
-(cond-expand
- (guile-2)
- (else
- (define-macro (eval-when conditions . forms)
- (if (or (memq 'eval conditions)
- (memq 'load conditions))
- `(begin . ,forms)
- '(begin)))
- (export eval-when)))
-
(define (force-bindings module)
(cond
((and (eq? (module-kind module) 'interface) (module-binder module))
diff --git a/glib/gnome/gw/support/slib.scm b/glib/gnome/gw/support/slib.scm
index 8b979ed..7c47558 100644
--- a/glib/gnome/gw/support/slib.scm
+++ b/glib/gnome/gw/support/slib.scm
@@ -33,12 +33,6 @@
(define (require feature) #f) ; noop
(define (require-if condition feature) #f) ; noop
-(cond-expand
- (guile-2
- (include-from-path "gnome/gw/support/glob.scm")
- (include-from-path "gnome/gw/support/genwrite.scm")
- (include-from-path "gnome/gw/support/printf.scm"))
- (else
- (load "glob.scm")
- (load "genwrite.scm")
- (load "printf.scm")))
+(include-from-path "gnome/gw/support/glob.scm")
+(include-from-path "gnome/gw/support/genwrite.scm")
+(include-from-path "gnome/gw/support/printf.scm")
--
2.1.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2014-10-07 22:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-07 22:54 guile-gnome, devel: removes guile-1.8 specific code and dependency David Pirotte
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).