chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] New string manipulation module


From: Jim Ursetto
Subject: Re: [Chicken-users] New string manipulation module
Date: Wed, 20 Feb 2013 14:46:20 -0600

I think it sounds good as an official egg; although there's a lot of overlap with SRFI-13 it's not bad to have another API.

The main thing I'd suggest if making it official is that, as a port of the s library, to name it something like "s" or "s-strings" instead of "strings", since the latter sounds like it would be the de-facto strings library for chicken.  By convention as a port of s.el I think "s" is the most appropriate name.  But I'm not sure if anyone else would agree.  (Just don't name it "slib"!)

I also think it's ok to keep the explicit s- prefix on your procedures.  Although Chicken does support module prefixing, having procedures like "join", "matches?", "equals?" and "match" in the first place is not very descriptive, and may conflict with commonly-used names.  However, "titlecase" is immediately obvious.  One option is to disambiguate the names, like "string-join" or "join-strings", and "string-match" or "match-string".  Another is to keep the s- prefix, which is a natural grouping.  Or you could require the user to prefix on import, but if that's always needed due to conflicts, why make them go through the extra step?  Ultimately, since there are no official guidelines for naming, it's up to you and your users.

Jim

On Feb 20, 2013, at 11:36 AM, Nicholas Van Horn wrote:

I'm new to Chicken (and scheme for that matter), but I'm eager to contribute. I've been working on several text processing projects for which I've ported an Emacs-lisp string manipulation library to Chicken.

The "strings" module provides many convenient string manipulation procedures (including new procedures not ported from the original elisp library). Each procedure is documented with examples. Beyond their immediate convenience, (I think) they present the user with a consistent API for working with strings.

I am eager to share this as an "official" egg, but being new to scheme I have likely violated common practices. I share the preliminary module here in the hopes that someone will find it useful. I welcome any feedback with respect to changes in implementation/behavior, as well as missing functionality that you would like to see added.

The module is packaged to be distributed as an egg, but it is currently only available at:

https://github.com/n3mo/strings

Thanks,
Nicholas Van Horn
_______________________________________________
Chicken-users mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/chicken-users


reply via email to

[Prev in Thread] Current Thread [Next in Thread]