Skip to content

Commit

Permalink
Checking in changes prior to tagging of version 0.02.
Browse files Browse the repository at this point in the history
Changelog diff is:

diff --git a/Changes b/Changes
index cccc82f..9cf7cf4 100644
--- a/Changes
+++ b/Changes
@@ -1,4 +1,9 @@
 Revision history for Perl extension Data::Section::Simple

+0.02  Thu Mar 18 15:14:44 PDT 2010
+        - Added a warning document about __DATA__ appearing elsewhere (rjbs)
+        - Fixed a bug installing via cpanm often fails because fileno $d
+          could be 0 when STDIN is closed (reported by rjbs)
+
 0.01  Thu Mar 18 01:06:44 2010
         - original version
  • Loading branch information
miyagawa committed Mar 18, 2010
1 parent 257c190 commit b4e5adb
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 7 deletions.
5 changes: 5 additions & 0 deletions Changes
Original file line number Original file line Diff line number Diff line change
@@ -1,4 +1,9 @@
Revision history for Perl extension Data::Section::Simple Revision history for Perl extension Data::Section::Simple


0.02 Thu Mar 18 15:14:44 PDT 2010
- Added a warning document about __DATA__ appearing elsewhere (rjbs)
- Fixed a bug installing via cpanm often fails because fileno $d
could be 0 when STDIN is closed (reported by rjbs)

0.01 Thu Mar 18 01:06:44 2010 0.01 Thu Mar 18 01:06:44 2010
- original version - original version
2 changes: 2 additions & 0 deletions MANIFEST
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ META.yml
README README
t/00_compile.t t/00_compile.t
t/basic.t t/basic.t
t/data.t
t/DataInCode.pm
t/Foo.pm t/Foo.pm
t/pkg_oo.t t/pkg_oo.t
xt/pod.t xt/pod.t
25 changes: 19 additions & 6 deletions README
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -29,14 +29,27 @@ DESCRIPTION
section of the file. section of the file.


LIMITATIONS LIMITATIONS
As the name suggests, it's a very simple version of what Data::Section As the name suggests, this module is a simpler version of the excellent
does. If you want more functionalities such as merging data sections or Data::Section. If you want more functionalities such as merging data
changing header patterns, use Data::Section instead. sections or changing header patterns, use Data::Section instead.


This module does not implement caching (yet) which means in every This module does not implement caching (yet) which means in every
"get_data_section" or "get_data_section($name)" seeks and reads the data "get_data_section" or "get_data_section($name)" this module seeks and
section every time it's called. If you want to avoid doing so, you re-reads the data section. If you want to avoid doing so for the better
should implement caching in your own caller code. performance, you should implement caching in your own caller code.

BUGS
If you data section has literal "__DATA__" in the data section, this
module might be tricked by that. Although since its pattern match is
greedy, "__DATA__" appearing *before* the actual data section (i.e. in
the code) might be okay.

This is by design -- in thoery you can "tell" the DATA handle before
reading it, but then reloading the data section of the file (handy for
developing inline templates with PSGI web applications) would fail
because the pos would be changed.

If you don't like this design, again, use the superior Data::Section.


AUTHOR AUTHOR
Tatsuhiko Miyagawa <miyagawa@bulknews.net> Tatsuhiko Miyagawa <miyagawa@bulknews.net>
Expand Down
2 changes: 1 addition & 1 deletion lib/Data/Section/Simple.pm
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package Data::Section::Simple;


use strict; use strict;
use 5.008_001; use 5.008_001;
our $VERSION = '0.01'; our $VERSION = '0.02';


use base qw(Exporter); use base qw(Exporter);
our @EXPORT_OK = qw(get_data_section); our @EXPORT_OK = qw(get_data_section);
Expand Down

0 comments on commit b4e5adb

Please sign in to comment.