Double speed of Model[pk] for models with simple datasets (most models)

The last time I optimized this, I got a similar speedup by using
static SQL instead of having the dataset generate it.  However,
after doing some profiling, it turns out most of the overhead then
became in the cloning of the dataset due to the use of with_sql
and first.  Skip the dataset cloning by using fetch_rows with
Model.call.

While here, refactor the static SQL handling so that it only
requires a String#dup and Dataset#literal_append call, which
adds an additional small speedup.

With these two changes, I'm getting about 2.1x the previous
performance for model lookups for an in memory SQLite database.

Because Model#simple_pk= and Model#simple_table= now exist as
private methods, they should be used instead of setting the
instance variables directly.
Remove some unnecessary proc activations
Dataset#disable_insert_returning on PostgreSQL is now deprecated and will be removed after 3.34.0 is released
Attempt to avoid proc activation for fetch_rows/each, which must always be passed a block

For MRI, proc activation is costly, so it's a good idea to attempt
to avoid it for methods that must be passed a block.  For methods
where a block is optional, the advantages are less clear cut, so
more analysis is needed for those cases.
Add tests for updating associated objects with _delete/_remove flags set to false.
Avoid complications with _delete/_remove flags being passed to nested_attributes_update if they are set to false: remove the _delete/_remove flags from attributes if deleting/removing the associated objects is configured. Do not modify the original attributes hash.
Rename block argument to Model.plugin for consistency
Avoid proc activation for Database#synchronize on MRI

Proc activation is cheap on jruby and rubinius, so using an explicit
block hurts there, but is significantly faster on MRI 1.8 and 1.9.
Remove unused variable.
Merge remote-tracking branch 'r-stu31/minor_cleanup'
Merge remote-tracking branch 'r-stu31/nested_attributes-_remove-_delete'
Update CHANGELOG
Add spec_model_no_assoc tasks for running model specs without the associations code

This should be used to check that the main model code has no
dependencies on the associations code.  There were a few places
in record_spec.rb that assumed the associations code was loaded,
move those specs to the associations spec.
Add spec to check that core extensions aren't used inside Sequel

Since 3.0, it's been Sequel's policy to not rely on the core
extensions internally, so that Sequel can be used safely with the
SEQUEL_NO_CORE_EXTENSIONS setting.  However, occassionally
such usage has snuck in, and it's generally not discovered unless
someone hits the code path with the core extensions disabled.

This spec will scan all of the Sequel files looking for core
extension usage, and will fail if it detects any.

This spec actually caught usage of the core extensions in the
shared PostgreSQL adapter that had been there for close to three
years.
Fix possible SystemStackError in SQLite adapter

Using filter here causes a SystemStackError if group/having was
already used on the dataset.  Switch to where since we always want
to modify the WHERE clause.
Refactor delete/update/insert/replace on mysql and mysql2 adapters

Previously, these methods were overridden in order to return
the correct value (affected rows/inserted id) using a block.
Instead, override Database#execute_dui and #execute_insert
which return the correct values, which lets the Dataset methods
use the standard implementation.

While here, make some other minor adjustments:

Add Dataset#replace to the shared mysql adapter, instead of
defining it in every adapter that connects to mysql.

Remove provides_accurate_rows_matched? from the native mysql
adapter.  Remove Dataset#execute_dui overrides from mysql and
mysql2 adapters, since the :type=>:dui setting isn't actually used.

Move MySQL::Dataset::AFFECTED_ROWS_RE constant to
MySQL::Database::AFFECTED_ROWS_RE, and private
Dataset#affected_rows method to Database#affected_rows.
Fix mock adapter Database#execute* if no dataset was used
Increase speed of Model#delete and #destroy by about 75% for models with simple datasets

This makes Model#delete and #destroy use a similar optimization as
Model.primary_key_lookup, caching the entire SQL query to use except
for the primary key.  Since no equivalent for fetch_rows exists for
delete, add a Dataset#with_sql_delete method that just calls the
private execute_dui method.  This is used so there is no need to
clone the model's dataset to execute the SQL.

While here, do some minor micro-ops like caching certain calls in
local variables.

Only significant fallout from this is in the instance_filters plugin,
so modify that not to use this optimization if an instance filter is
being used.
Make core extension spec work on 1.8.6 since that is still supported
Increase speed of Model#this by about 85%

Previously, this was doing 3 dataset clones.  Add a
Model.instance_dataset method that returns a cached intermediate
dataset, so that Model#this only has to do one dataset clone.

Quite a bit of spec fallout since the specs assumed that you could
modify Model.dataset when you now need to modify
Model.instance_dataset.