mirror of
https://github.com/DBD-SQLite/DBD-SQLite
synced 2025-06-07 14:19:10 -04:00
added a script to see which API was introduced when
This commit is contained in:
parent
305d556b5b
commit
c3571f0c11
1 changed files with 33 additions and 0 deletions
33
util/api_history.pl
Normal file
33
util/api_history.pl
Normal file
|
@ -0,0 +1,33 @@
|
|||
#!/usr/bin/perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use FindBin;
|
||||
use lib "$FindBin::Bin";
|
||||
use SQLiteUtil;
|
||||
use Array::Diff;
|
||||
|
||||
my %current;
|
||||
for my $version (versions()) {
|
||||
print "checking $version...\n";
|
||||
my $dir = srcdir($version);
|
||||
unless ($dir && -d $dir) {
|
||||
$dir = mirror($version) or next;
|
||||
}
|
||||
my %constants = extract_constants("$dir/sqlite3.h");
|
||||
if (%current) {
|
||||
for (sort keys %current) {
|
||||
print "$version: deleted $_\n" if !exists $constants{$_};
|
||||
}
|
||||
for (sort keys %constants) {
|
||||
if (!exists $current{$_}) {
|
||||
print "$version: added $_\n";
|
||||
next;
|
||||
}
|
||||
my $diff = Array::Diff->diff($current{$_}, $constants{$_});
|
||||
print "$version: added $_\n" for @{$diff->added || []};
|
||||
print "$version: deleted $_\n" for @{$diff->deleted || []};
|
||||
}
|
||||
}
|
||||
%current = %constants;
|
||||
}
|
Loading…
Add table
Reference in a new issue