From 1a80b6b04489a684a4a396588b306ccdede5f9b5 Mon Sep 17 00:00:00 2001 From: Sam Tobin-Hochstadt Date: Fri, 11 Jun 2010 16:53:13 -0400 Subject: [PATCH] Include "-" in last name regexp. --- collects/scriblib/autobib.rkt | 2 +- collects/scriblib/scribblings/autobib.scrbl | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/collects/scriblib/autobib.rkt b/collects/scriblib/autobib.rkt index 79b0c79f2d..7083853d9a 100644 --- a/collects/scriblib/autobib.rkt +++ b/collects/scriblib/autobib.rkt @@ -189,7 +189,7 @@ (if (author-element? a) a (let* ([s (content->string a)] - [m (regexp-match #px"^(.*) (\\p{L}+)$" s)]) + [m (regexp-match #px"^(.*) (([\\-]|\\p{L})+)$" s)]) (make-author-element #f (list a) diff --git a/collects/scriblib/scribblings/autobib.scrbl b/collects/scriblib/scribblings/autobib.scrbl index 658dca1003..66a7c57cf3 100644 --- a/collects/scriblib/scribblings/autobib.scrbl +++ b/collects/scriblib/scribblings/autobib.scrbl @@ -70,9 +70,9 @@ standard format. An element produced by a function like @scheme[author-name] tracks first, last names, and name suffixes separately, so that names can be ordered and rendered correctly. When a string is provided as an author -name, the last non-empty sequence of ASCII alphabetic characters after -a space is treated as the author name, and the rest is treated as the -first name.} +name, the last non-empty sequence of alphabetic characters or +@litchar["-"] after a space is treated as the author name, and the +rest is treated as the first name.} @defproc[(in-bib [orig bib?] [where string?]) bib?]{