From: Peter Rabbitson <ribasushi@cpan.org>
Date: Thu, 10 Apr 2014 22:38:10 +0000 (+0200)
Subject: Clarify that sql_maker is just a getter at this point
X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3a3ebbbe64caf0b9f790f8cc88a5eeab75e128da;p=dbsrgits%2FDBIx-Class-Historic.git

Clarify that sql_maker is just a getter at this point
---

diff --git a/lib/DBIx/Class/Storage/DBI.pm b/lib/DBIx/Class/Storage/DBI.pm
index 9b5e3b0..5245bea 100644
--- a/lib/DBIx/Class/Storage/DBI.pm
+++ b/lib/DBIx/Class/Storage/DBI.pm
@@ -991,8 +991,13 @@ sub _get_dbh {
   return $self->_dbh;
 }
 
+# *DELIBERATELY* not a setter (for the time being)
+# Too intertwined with everything else for any kind of sanity
 sub sql_maker {
-  my ($self) = @_;
+  my $self = shift;
+
+  $self->throw_exception('sql_maker() is not a setter method') if @_;
+
   unless ($self->_sql_maker) {
     my $sql_maker_class = $self->sql_maker_class;