mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (Default)
Mark Smith ([staff profile] mark) wrote in [site community profile] changelog2009-09-30 05:45 am

[dw-free] Eliminate Class::Autouse from the code

[commit: http://hg.dwscoalition.org/dw-free/rev/0732b0ee3f52]

http://bugs.dwscoalition.org/show_bug.cgi?id=1761

Continue removal of Class::AutoUse.

Patch by [personal profile] szabgab.

Files modified:
  • cgi-bin/LJ/CProd.pm
  • cgi-bin/LJ/Console/Command/Help.pm
  • cgi-bin/LJ/ESN.pm
  • cgi-bin/LJ/EmbedModule.pm
  • cgi-bin/LJ/Event.pm
  • cgi-bin/LJ/Event/CommunityInvite.pm
  • cgi-bin/LJ/Event/CommunityJoinRequest.pm
  • cgi-bin/LJ/Event/JournalNewComment.pm
  • cgi-bin/LJ/Event/JournalNewEntry.pm
  • cgi-bin/LJ/Event/NewUserpic.pm
  • cgi-bin/LJ/Event/OfficialPost.pm
  • cgi-bin/LJ/Event/PollVote.pm
  • cgi-bin/LJ/Event/UserNewComment.pm
  • cgi-bin/LJ/Event/UserNewEntry.pm
  • cgi-bin/LJ/NotificationArchive.pm
  • cgi-bin/LJ/NotificationItem.pm
  • cgi-bin/LJ/NotificationMethod/Inbox.pm
  • cgi-bin/LJ/S2/FriendsPage.pm
  • cgi-bin/LJ/User.pm
  • cgi-bin/LJ/Widget/AddQotD.pm
  • cgi-bin/LJ/Widget/CreateAccount.pm
  • cgi-bin/LJ/Widget/ManageSiteMessages.pm
  • cgi-bin/LJ/Widget/NavStripChooser.pm
  • cgi-bin/LJ/Widget/S2PropGroup.pm
  • cgi-bin/LJ/Worker.pm
--------------------------------------------------------------------------------
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/CProd.pm
--- a/cgi-bin/LJ/CProd.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/CProd.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -4,7 +4,7 @@ package LJ::CProd;
 # Let users know about new/old features they can use but never have.
 use strict;
 use List::Util qw (shuffle);
-use Class::Autouse qw (LJ::Typemap);
+use LJ::Typemap;
 
 #################### Override:
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Console/Command/Help.pm
--- a/cgi-bin/LJ/Console/Command/Help.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Console/Command/Help.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,10 +3,8 @@ use strict;
 use strict;
 use base qw(LJ::Console::Command);
 use Carp qw(croak);
-use Class::Autouse qw(
-                      Text::Wrap
-                      LJ::ModuleLoader
-                      );
+use Text::Wrap;
+use LJ::ModuleLoader;
 
 my @CLASSES = LJ::ModuleLoader->module_subclasses("LJ::Console::Command");
 foreach my $class (@CLASSES) {
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/ESN.pm
--- a/cgi-bin/LJ/ESN.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/ESN.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,11 +1,8 @@ package LJ::ESN;
 package LJ::ESN;
 use strict;
 use Carp qw(croak);
-use Class::Autouse qw(
-                      LJ::Event
-                      LJ::Subscription
-                      );
-
+use LJ::Event;
+use LJ::Subscription;
 use Data::Dumper;
 
 our $MAX_FILTER_SET = 5_000;
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/EmbedModule.pm
--- a/cgi-bin/LJ/EmbedModule.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/EmbedModule.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -2,10 +2,8 @@ package LJ::EmbedModule;
 package LJ::EmbedModule;
 use strict;
 use Carp qw (croak);
-use Class::Autouse qw (
-                       LJ::Auth
-                       HTML::TokeParser
-                       );
+use LJ::Auth;
+use HTML::TokeParser;
 
 # states for a finite-state machine we use in parse()
 use constant {
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event.pm
--- a/cgi-bin/LJ/Event.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -4,11 +4,9 @@ no warnings 'uninitialized';
 
 use Carp qw(croak);
 use LJ::ModuleLoader;
-use Class::Autouse qw(
-                      LJ::ESN
-                      LJ::Subscription
-                      LJ::Typemap
-                      );
+use LJ::ESN;
+use LJ::Subscription;
+use LJ::Typemap;
 
 my @EVENTS = LJ::ModuleLoader->module_subclasses("LJ::Event");
 foreach my $event (@EVENTS) {
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/CommunityInvite.pm
--- a/cgi-bin/LJ/Event/CommunityInvite.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/CommunityInvite.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,6 +1,6 @@ package LJ::Event::CommunityInvite;
 package LJ::Event::CommunityInvite;
 use strict;
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/CommunityJoinRequest.pm
--- a/cgi-bin/LJ/Event/CommunityJoinRequest.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/CommunityJoinRequest.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,6 +1,6 @@ package LJ::Event::CommunityJoinRequest;
 package LJ::Event::CommunityJoinRequest;
 use strict;
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/JournalNewComment.pm
--- a/cgi-bin/LJ/Event/JournalNewComment.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/JournalNewComment.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,7 +1,8 @@ package LJ::Event::JournalNewComment;
 package LJ::Event::JournalNewComment;
 use strict;
 use Scalar::Util qw(blessed);
-use Class::Autouse qw(LJ::Comment LJ::HTML::Template);
+use LJ::Comment;
+use LJ::HTML::Template;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/JournalNewEntry.pm
--- a/cgi-bin/LJ/Event/JournalNewEntry.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/JournalNewEntry.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -4,7 +4,7 @@ package LJ::Event::JournalNewEntry;
 package LJ::Event::JournalNewEntry;
 use strict;
 use Scalar::Util qw(blessed);
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/NewUserpic.pm
--- a/cgi-bin/LJ/Event/NewUserpic.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/NewUserpic.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,7 +1,7 @@ package LJ::Event::NewUserpic;
 package LJ::Event::NewUserpic;
 use strict;
 use base 'LJ::Event';
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use Carp qw(croak);
 
 sub new {
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/OfficialPost.pm
--- a/cgi-bin/LJ/Event/OfficialPost.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/OfficialPost.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,6 +1,6 @@ package LJ::Event::OfficialPost;
 package LJ::Event::OfficialPost;
 use strict;
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/PollVote.pm
--- a/cgi-bin/LJ/Event/PollVote.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/PollVote.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,7 +1,7 @@ package LJ::Event::PollVote;
 package LJ::Event::PollVote;
 use strict;
 use base 'LJ::Event';
-use Class::Autouse qw(LJ::Poll);
+use LJ::Poll;
 use Carp qw(croak);
 
 # we need to specify 'owner' here, because subscriptions are tied
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/UserNewComment.pm
--- a/cgi-bin/LJ/Event/UserNewComment.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/UserNewComment.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -1,7 +1,7 @@ package LJ::Event::UserNewComment;
 package LJ::Event::UserNewComment;
 use strict;
 use Scalar::Util qw(blessed);
-use Class::Autouse qw(LJ::Comment);
+use LJ::Comment;
 use Carp qw(croak);
 use base 'LJ::Event';
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Event/UserNewEntry.pm
--- a/cgi-bin/LJ/Event/UserNewEntry.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Event/UserNewEntry.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -7,7 +7,7 @@ use strict;
 use strict;
 use Scalar::Util qw(blessed);
 use Carp qw(croak);
-use Class::Autouse qw(LJ::Entry);
+use LJ::Entry;
 use base 'LJ::Event';
 
 ############################################################################
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/NotificationArchive.pm
--- a/cgi-bin/LJ/NotificationArchive.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/NotificationArchive.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -6,7 +6,8 @@ package LJ::NotificationArchive;
 
 use strict;
 use Carp qw(croak);
-use Class::Autouse qw (LJ::NotificationItem LJ::Event);
+use LJ::NotificationItem;
+use LJ::Event;
 
 *new = \&instance;
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/NotificationItem.pm
--- a/cgi-bin/LJ/NotificationItem.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/NotificationItem.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -9,10 +9,8 @@ use warnings;
 use warnings;
 no warnings "redefine";
 
-use Class::Autouse qw(
-                      LJ::NotificationInbox
-                      LJ::Event
-                      );
+use LJ::NotificationInbox;
+use LJ::Event;
 use Carp qw(croak);
 
 *new = \&instance;
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/NotificationMethod/Inbox.pm
--- a/cgi-bin/LJ/NotificationMethod/Inbox.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/NotificationMethod/Inbox.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@ use strict;
 use strict;
 use Carp qw/ croak /;
 use base 'LJ::NotificationMethod';
-use Class::Autouse qw(LJ::NotificationInbox);
+use LJ::NotificationInbox;
 
 sub can_digest { 1 };
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/S2/FriendsPage.pm
--- a/cgi-bin/LJ/S2/FriendsPage.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/S2/FriendsPage.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@
 
 use strict;
 package LJ::S2;
-use Class::Autouse qw/ DW::Logic::AdultContent /;
+use DW::Logic::AdultContent;
 
 sub FriendsPage
 {
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/User.pm
--- a/cgi-bin/LJ/User.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/User.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -28,17 +28,15 @@ use DW::User::ContentFilters;
 use DW::User::ContentFilters;
 use DW::User::Edges;
 
-use Class::Autouse qw(
-                      LJ::Subscription
-                      LJ::Identity
-                      LJ::Auth
-                      LJ::Jabber::Presence
-                      LJ::S2
-                      IO::Socket::INET
-                      Time::Local
-                      LJ::BetaFeatures
-                      LJ::S2Theme
-                      );
+use LJ::Subscription;
+use LJ::Identity;
+use LJ::Auth;
+use LJ::Jabber::Presence;
+use LJ::S2;
+use IO::Socket::INET;
+use Time::Local;
+use LJ::BetaFeatures;
+use LJ::S2Theme;
 
 ########################################################################
 ### Please keep these categorized and alphabetized for ease of use. 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Widget/AddQotD.pm
--- a/cgi-bin/LJ/Widget/AddQotD.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Widget/AddQotD.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@ use strict;
 use strict;
 use base qw(LJ::Widget);
 use Carp qw(croak);
-use Class::Autouse qw( LJ::QotD );
+use LJ::QotD;
 
 sub need_res { }
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Widget/CreateAccount.pm
--- a/cgi-bin/LJ/Widget/CreateAccount.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Widget/CreateAccount.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,8 @@ use strict;
 use strict;
 use base qw(LJ::Widget);
 use Carp qw(croak);
-use Class::Autouse qw( LJ::CreatePage Captcha::reCAPTCHA );
+use LJ::CreatePage;
+use Captcha::reCAPTCHA;
 
 sub need_res { qw( stc/widgets/createaccount.css js/widgets/createaccount.js js/browserdetect.js ) }
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Widget/ManageSiteMessages.pm
--- a/cgi-bin/LJ/Widget/ManageSiteMessages.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Widget/ManageSiteMessages.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@ use strict;
 use strict;
 use base qw(LJ::Widget);
 use Carp qw(croak);
-use Class::Autouse qw( LJ::SiteMessages );
+use LJ::SiteMessages;
 
 sub need_res { }
 
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Widget/NavStripChooser.pm
--- a/cgi-bin/LJ/Widget/NavStripChooser.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Widget/NavStripChooser.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@ use strict;
 use strict;
 use base qw(LJ::Widget);
 use Carp qw(croak);
-use Class::Autouse qw( LJ::Customize );
+use LJ::Customize;
 
 sub ajax { 1 }
 sub authas { 1 }
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Widget/S2PropGroup.pm
--- a/cgi-bin/LJ/Widget/S2PropGroup.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Widget/S2PropGroup.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -3,7 +3,7 @@ use strict;
 use strict;
 use base qw(LJ::Widget);
 use Carp qw(croak);
-use Class::Autouse qw( LJ::Customize );
+use LJ::Customize;
 
 sub authas { 1 }
 sub need_res { qw( stc/widgets/s2propgroup.css js/colorpicker.js ) }
diff -r 367ea0e1c193 -r 0732b0ee3f52 cgi-bin/LJ/Worker.pm
--- a/cgi-bin/LJ/Worker.pm	Wed Sep 30 04:53:17 2009 +0000
+++ b/cgi-bin/LJ/Worker.pm	Wed Sep 30 05:45:45 2009 +0000
@@ -5,11 +5,6 @@ use POSIX ();
 
 use strict;
 
-
-# this will force preloading (rather than lazy) or all
-# modules so they're loaded in shared memory before the
-# fork (mod_perl-style)
-use Class::Autouse qw{:devel};
 
 BEGIN {
     my $debug = $ENV{DEBUG} ? 1 : 0;
--------------------------------------------------------------------------------